fix numOfBytes variable name not changed in the rest of the function call
This commit is contained in:
parent
a1a3598d82
commit
bf8e96010d
@ -127,11 +127,11 @@ def formatTime(timeInSeconds, weeksAsTitles=True):
|
|||||||
return formattedTime
|
return formattedTime
|
||||||
|
|
||||||
|
|
||||||
def formatSize(num_of_bytes, precise=False):
|
def formatSize(numOfBytes, precise=False):
|
||||||
if bytes == 0: # E.g. when file size privacy is enabled
|
if numOfBytes == 0: # E.g. when file size privacy is enabled
|
||||||
return "???"
|
return "???"
|
||||||
try:
|
try:
|
||||||
megabytes = int(bytes) / 1048576.0 # Technically this is a mebibyte, but whatever
|
megabytes = int(numOfBytes) / 1048576.0 # Technically this is a mebibyte, but whatever
|
||||||
if precise:
|
if precise:
|
||||||
megabytes = round(megabytes, 1)
|
megabytes = round(megabytes, 1)
|
||||||
else:
|
else:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user