mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-06 01:05:48 +02:00
Ensure mimetype is sent to github
This commit is contained in:
@@ -257,7 +257,7 @@ class GitHub(Base): # {{{
|
||||
% (asset['name'], release['tag_name']))
|
||||
|
||||
def do_upload(self, url: str, path: str, desc: str, fname: str) -> requests.Response:
|
||||
mime_type = mimetypes.guess_type(fname)[0]
|
||||
mime_type = mimetypes.guess_type(fname)[0] or 'application/octet-stream'
|
||||
self.info('Uploading to GitHub: %s (%s)' % (fname, mime_type))
|
||||
with ReadFileWithProgressReporting(path) as f:
|
||||
return self.requests.post(
|
||||
|
||||
Reference in New Issue
Block a user