do not try to read hidden directories ()

pull/3637/head
Kaalleen 2025-04-06 08:53:06 +02:00 zatwierdzone przez GitHub
rodzic d252f5f109
commit 11e0676aba
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: B5690EEEBB952194
1 zmienionych plików z 2 dodań i 0 usunięć
lib/lettering

Wyświetl plik

@ -48,6 +48,8 @@ def get_font_by_id(font_id):
except OSError:
continue
for font_dir in font_dirs:
if not os.path.isdir(os.path.join(font_path, font_dir)) or font_dir.startswith('.'):
continue
font = Font(os.path.join(font_path, font_dir))
if font.id == font_id:
return font