Fix saving a loaded file as another existing file.

This commit is contained in:
John Preston
2017-08-01 20:17:59 +03:00
parent 27151d5e25
commit 91f0d049db
2 changed files with 7 additions and 2 deletions
+1
View File
@@ -1889,6 +1889,7 @@ void DocumentData::save(const QString &toFile, ActionOnLoad action, const FullMs
} else if (l.accessEnable()) {
auto alreadyName = l.name();
if (alreadyName != toFile) {
QFile(toFile).remove();
QFile(alreadyName).copy(toFile);
}
l.accessDisable();