Private GIT

Skip to content
Snippets Groups Projects
Commit b786949b authored by labrys's avatar labrys
Browse files

Fix unicode for pretty_file_size.

parent 89a68d04
No related branches found
No related tags found
No related merge requests found
......@@ -63,11 +63,9 @@ def pretty_file_size(size):
:param size: The size to convert
:return: The converted size
"""
if isinstance(size, str) and size.isdigit():
if isinstance(size, (str, unicode)) and size.isdigit():
size = float(size)
if not isinstance(size, (int, long, float)):
elif not isinstance(size, (int, long, float)):
return ''
remaining_size = size
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment