Merge pull request #26 from gissehel/robustkey
The code was not robust anymore in weird cases where file['k']=='', it is now.
This commit is contained in:
commit
fc96c963e4
1 changed files with 1 additions and 1 deletions
|
@ -106,7 +106,7 @@ class Mega(object):
|
||||||
Process a file
|
Process a file
|
||||||
"""
|
"""
|
||||||
if file['t'] == 0 or file['t'] == 1:
|
if file['t'] == 0 or file['t'] == 1:
|
||||||
keys = dict(keypart.split(':', 1) for keypart in file['k'].split('/'))
|
keys = dict(keypart.split(':', 1) for keypart in file['k'].split('/') if ':' in keypart)
|
||||||
uid = file['u']
|
uid = file['u']
|
||||||
key = None
|
key = None
|
||||||
# my objects
|
# my objects
|
||||||
|
|
Loading…
Reference in a new issue