mirror of
https://github.com/overte-org/overte.git
synced 2025-04-25 00:56:48 +02:00
Merge pull request #102 from birarda/atp-mappings
append a trailing slash for folder rename
This commit is contained in:
commit
843bff1dcf
1 changed files with 5 additions and 0 deletions
|
@ -73,6 +73,11 @@ Window {
|
|||
newPath = "/" + newPath;
|
||||
}
|
||||
|
||||
if (oldPath[oldPath.length - 1] == '/' && newPath[newPath.length - 1] != '/') {
|
||||
// this is a folder rename but the user neglected to add a trailing slash when providing a new path
|
||||
newPath = newPath + "/";
|
||||
}
|
||||
|
||||
if (Assets.isKnownFolder(newPath)) {
|
||||
box = errorMessageBox("Cannot overwrite existing directory.");
|
||||
box.selected.connect(reload);
|
||||
|
|
Loading…
Reference in a new issue