mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-08 06:32:35 +02:00
Update backup formats to filter out non-whitelisted characters
This commit is contained in:
parent
dbfbee5406
commit
cd9cdea3e8
1 changed files with 3 additions and 1 deletions
|
@ -74,7 +74,9 @@ void DomainContentBackupManager::parseBackupRules(const QVariantList& backupRule
|
|||
int interval = map["backupInterval"].toInt();
|
||||
int count = map["maxBackupVersions"].toInt();
|
||||
auto name = map["Name"].toString();
|
||||
auto format = name.replace(" ", "_").toLower();
|
||||
auto format = name.toLower();
|
||||
QRegExp matchDisallowedCharacters { "[^a-zA-Z0-9\\-_]+" };
|
||||
format.replace(matchDisallowedCharacters, "_");
|
||||
|
||||
qCDebug(domain_server) << " Name:" << name;
|
||||
qCDebug(domain_server) << " format:" << format;
|
||||
|
|
Loading…
Reference in a new issue