mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-26 02:55:25 +02:00
Fix filename not being passed in correctly
This commit is contained in:
parent
1e36a5b218
commit
85c1739df4
1 changed files with 2 additions and 11 deletions
|
@ -357,15 +357,6 @@ void DomainContentBackupManager::getAllBackupsAndStatus(MiniPromise::Promise pro
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
QDir backupDir { _backupDirectory };
|
|
||||||
auto matchingFiles =
|
|
||||||
backupDir.entryInfoList({ AUTOMATIC_BACKUP_PREFIX + "*.zip", MANUAL_BACKUP_PREFIX + "*.zip" },
|
|
||||||
QDir::Files | QDir::NoSymLinks, QDir::Name);
|
|
||||||
QString prefixFormat = "(" + QRegExp::escape(AUTOMATIC_BACKUP_PREFIX) + "|" + QRegExp::escape(MANUAL_BACKUP_PREFIX) + ")";
|
|
||||||
QString nameFormat = "(.+)";
|
|
||||||
QString dateTimeFormat = "(" + DATETIME_FORMAT_RE + ")";
|
|
||||||
QRegExp backupNameFormat { prefixFormat + nameFormat + "-" + dateTimeFormat + "\\.zip" };
|
|
||||||
|
|
||||||
auto backups = getAllBackups();
|
auto backups = getAllBackups();
|
||||||
|
|
||||||
QVariantList variantBackups;
|
QVariantList variantBackups;
|
||||||
|
@ -376,7 +367,7 @@ void DomainContentBackupManager::getAllBackupsAndStatus(MiniPromise::Promise pro
|
||||||
for (auto& handler : _backupHandlers) {
|
for (auto& handler : _backupHandlers) {
|
||||||
bool handlerIsAvailable { true };
|
bool handlerIsAvailable { true };
|
||||||
float progress { 0.0f };
|
float progress { 0.0f };
|
||||||
std::tie(handlerIsAvailable, progress) = handler->isAvailable(backup.name);
|
std::tie(handlerIsAvailable, progress) = handler->isAvailable(backup.id);
|
||||||
isAvailable &= handlerIsAvailable;
|
isAvailable &= handlerIsAvailable;
|
||||||
availabilityProgress += progress / _backupHandlers.size();
|
availabilityProgress += progress / _backupHandlers.size();
|
||||||
}
|
}
|
||||||
|
@ -462,7 +453,7 @@ void DomainContentBackupManager::load() {
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto& handler : _backupHandlers) {
|
for (auto& handler : _backupHandlers) {
|
||||||
handler->loadBackup(backup.name, zip);
|
handler->loadBackup(backup.id, zip);
|
||||||
}
|
}
|
||||||
|
|
||||||
zip.close();
|
zip.close();
|
||||||
|
|
Loading…
Reference in a new issue