From cd804470b57556f49e2484b9d54d49c33bca61dc Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Fri, 18 Jun 2021 11:51:33 +0200 Subject: [PATCH] [partition] Canonicalize the FS choice for erase --- src/modules/partition/core/Config.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/modules/partition/core/Config.cpp b/src/modules/partition/core/Config.cpp index 78296018a..b09f1424d 100644 --- a/src/modules/partition/core/Config.cpp +++ b/src/modules/partition/core/Config.cpp @@ -9,6 +9,8 @@ #include "Config.h" +#include "PartUtils.h" + #include "GlobalStorage.h" #include "JobQueue.h" #include "utils/Logger.h" @@ -210,11 +212,11 @@ Config::setSwapChoice( Config::SwapChoice c ) void Config::setEraseFsTypeChoice( const QString& choice ) { - if ( choice != m_eraseFsTypeChoice ) + QString canonicalChoice = PartUtils::canonicalFilesystemName( choice, nullptr ); + if ( canonicalChoice != m_eraseFsTypeChoice ) { - // FIXME: shouldn't this be a canonical fs name? - m_eraseFsTypeChoice = choice; - Q_EMIT eraseModeFilesystemChanged( choice ); + m_eraseFsTypeChoice = canonicalChoice; + Q_EMIT eraseModeFilesystemChanged( canonicalChoice ); } }