summaryrefslogtreecommitdiff
path: root/git/objects/blob.py
diff options
context:
space:
mode:
Diffstat (limited to 'git/objects/blob.py')
-rw-r--r--git/objects/blob.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/git/objects/blob.py b/git/objects/blob.py
index 897f892b..017178f0 100644
--- a/git/objects/blob.py
+++ b/git/objects/blob.py
@@ -23,11 +23,11 @@ class Blob(base.IndexObject):
__slots__ = ()
@property
- def mime_type(self):
+ def mime_type(self) -> str:
"""
:return: String describing the mime type of this file (based on the filename)
:note: Defaults to 'text/plain' in case the actual file type is unknown. """
guesses = None
if self.path:
- guesses = guess_type(self.path)
+ guesses = guess_type(str(self.path))
return guesses and guesses[0] or self.DEFAULT_MIME_TYPE