don't call os.path.basename when folder was not found
This commit is contained in:
parent
68a2557884
commit
b6c4956521
1 changed files with 1 additions and 1 deletions
|
@ -168,7 +168,7 @@ def find_project_from_folders(folders, current_file):
|
|||
"""
|
||||
|
||||
folder = find_folder_containing_file(folders, current_file)
|
||||
return os.path.basename(folder)
|
||||
return os.path.basename(folder) if folder else None
|
||||
|
||||
|
||||
def handle_action(view, is_write=False):
|
||||
|
|
Loading…
Reference in a new issue