Remove unwanted trailing characters and other white spaces when reading .md5sum files.

This commit is contained in:
grossmj 2018-06-05 00:01:20 +07:00
parent 051eedb406
commit f8bf749577

View File

@ -156,7 +156,7 @@ def md5sum(path):
try:
with open(path + '.md5sum') as f:
md5 = f.read()
md5 = f.read().strip()
if len(md5) == 32:
return md5
# Unicode error is when user rename an image to .md5sum ....