Skip to content

Commit

Permalink
Merge pull request #148 from codingPF/Issue135
Browse files Browse the repository at this point in the history
apply patch from ahpohl for #135
  • Loading branch information
alex1702 authored Apr 29, 2020
2 parents a4ac9e8 + 40154a9 commit ca3eb81
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion resources/lib/mvupdate.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ def _log(self, level, message, *args):
parts = []
for arg in args:
part = arg
if isinstance(arg, basestring):
if isinstance(arg, str):
part = arg # arg.decode('utf-8')
parts.append(part)
output = '{} {} {}{}'.format(
Expand Down
4 changes: 2 additions & 2 deletions resources/lib/mvutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,8 @@ def build_url(query):
def _chunked_url_copier(src, dst, reporthook, chunk_size, aborthook):
aborthook = aborthook if aborthook is not None else lambda: False
total_size = int(
src.info().getheader('Content-Length').strip()
) if src.info() and src.info().getheader('Content-Length') else 0
src.info().get('Content-Length').strip()
) if src.info() and src.info().get('Content-Length') else 0
total_chunks = 0

while not aborthook():
Expand Down
2 changes: 1 addition & 1 deletion resources/lib/storesqlite.py
Original file line number Diff line number Diff line change
Expand Up @@ -986,7 +986,7 @@ def ft_insert_film(self, film, commit=True):

# check if the movie is there
idhash = hashlib.md5("{}:{}:{}".format(
self.ft_channelid, self.ft_showid, film['url_video'])).hexdigest()
self.ft_channelid, self.ft_showid, film['url_video']).encode('utf8')).hexdigest()
cursor.execute("""
SELECT `id`,
`touched`
Expand Down
2 changes: 1 addition & 1 deletion resources/lib/updater.py
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ def get_newest_list(self, full):
self.notifier.show_download_error(url, err)
return False
except Exception as err:
self.logger.error('Failure writng {}', url)
self.logger.error('Failure writing {}', url)
self.notifier.close_download_progress()
self.notifier.show_download_error(url, err)
return False
Expand Down

0 comments on commit ca3eb81

Please sign in to comment.