mirror of
https://github.com/overte-org/overte.git
synced 2025-08-07 04:14:38 +02:00
Merge pull request #12487 from Atlante45/feat/backups-integration
Actually remove Backup from list during delete
This commit is contained in:
commit
4c44bcfdba
1 changed files with 3 additions and 1 deletions
|
@ -339,7 +339,7 @@ void AssetsBackupHandler::deleteBackup(const QString& backupName) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto it = find_if(begin(_backups), end(_backups), [&](const AssetServerBackup& backup) {
|
const auto it = remove_if(begin(_backups), end(_backups), [&](const AssetServerBackup& backup) {
|
||||||
return backup.name == backupName;
|
return backup.name == backupName;
|
||||||
});
|
});
|
||||||
if (it == end(_backups)) {
|
if (it == end(_backups)) {
|
||||||
|
@ -347,6 +347,8 @@ void AssetsBackupHandler::deleteBackup(const QString& backupName) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
_backups.erase(it, end(_backups));
|
||||||
|
|
||||||
refreshAssetsInBackups();
|
refreshAssetsInBackups();
|
||||||
checkForAssetsToDelete();
|
checkForAssetsToDelete();
|
||||||
qDebug() << "Deleted asset backup:" << backupName;
|
qDebug() << "Deleted asset backup:" << backupName;
|
||||||
|
|
Loading…
Reference in a new issue