mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-09 13:45:26 +02:00
Check for dirs when getting mimetypes in a couple more places
This commit is contained in:
@@ -155,7 +155,7 @@ def sanitize(text: str) -> str:
|
||||
|
||||
@lru_cache(maxsize=1024)
|
||||
def mime_type_for_path(path: str) -> str:
|
||||
return guess_type(path) or 'application/octet-stream'
|
||||
return guess_type(path, allow_filesystem_access=True) or 'application/octet-stream'
|
||||
|
||||
|
||||
@lru_cache(maxsize=1024)
|
||||
|
||||
Reference in New Issue
Block a user