mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-03-06 14:27:43 +00:00
Added a (very long) length restriction to custom collection names
This commit is contained in:
parent
6c3406c9d8
commit
b975fce8ff
|
@ -559,6 +559,11 @@ std::string CollectionSystemsManager::getValidNewCollectionName(const std::strin
|
|||
{
|
||||
std::string name {inName};
|
||||
|
||||
if (name.length() > 160) {
|
||||
LOG(LogWarning) << "Requested custom collection name is too long, shortening it";
|
||||
name = name.substr(0, 160);
|
||||
}
|
||||
|
||||
if (index == 0) {
|
||||
size_t remove {std::string::npos};
|
||||
// Remove invalid characters.
|
||||
|
|
Loading…
Reference in a new issue