Simplify this call to makedirs with destination.parent.
This commit is contained in:
parent
b34f6fafed
commit
26eaac7119
1 changed files with 1 additions and 2 deletions
|
@ -420,9 +420,8 @@ def copy_file(
|
|||
return [destination, 0]
|
||||
|
||||
source_bytes = source.size
|
||||
destination_location = os.path.split(destination.absolute_path)[0]
|
||||
os.makedirs(destination_location, exist_ok=True)
|
||||
|
||||
os.makedirs(destination.parent.absolute_path, exist_ok=True)
|
||||
def handlehelper(path, mode):
|
||||
try:
|
||||
handle = open(path.absolute_path, mode)
|
||||
|
|
Loading…
Reference in a new issue