mirror of
https://github.com/rwinkhart/libmutton.git
synced 2026-10-27 06:09:56 -04:00
Fix renaming an entry/folder to an invalid path still attempting the rename on the server
This commit is contained in:
1 parent
7b4241b2cd
commit
1fb2834844
1 file changed
+1
@@ -88,6 +88,7 @@ func RenameLocal(oldLocationIncomplete, newLocationIncomplete string, verifyOldL
|
|||||||
err := os.Rename(oldLocation, newLocation)
|
err := os.Rename(oldLocation, newLocation)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println(core.AnsiError + "Failed to rename - Does the target containing directory exist?" + core.AnsiReset)
|
fmt.Println(core.AnsiError + "Failed to rename - Does the target containing directory exist?" + core.AnsiReset)
|
||||||
|
os.Exit(core.ErrorTargetNotFound)
|
||||||
}
|
}
|
||||||
|
|
||||||
// do not exit program, as this function is used as part of RenameRemoteFromClient
|
// do not exit program, as this function is used as part of RenameRemoteFromClient
|
||||||
|
|||||||
Reference in new issue
Block a user