RMG: simplify sanitizing filename in RomBrowserWidget

This commit is contained in:
Rosalie Wanders committed 2023-02-24 00:46:07 +01:00
1 parent 9cfda8514e
commit e7767105d6
1 file changed
+1 -7
@@ -390,14 +390,8 @@ QIcon RomBrowserWidget::getCurrentCover(QString file, CoreRomHeader header, Core
{
// fixup file name
QString fixedName = name;
for (const char c : ":<>\"/\\|?*")
for (const QChar c : QString(":<>\"/\\|?*"))
{
// skip empty characters
if (c == '\0')
{
continue;
}
fixedName.replace(c, "_");
}