From 890fbb8b55b375565ea8a7c79a90d33a37fc81ec Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Fri, 22 Apr 2005 04:28:46 +0000 Subject: [PATCH] simplify --- stepmania/src/ProfileManager.cpp | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/stepmania/src/ProfileManager.cpp b/stepmania/src/ProfileManager.cpp index b583506936..328a6e39e2 100644 --- a/stepmania/src/ProfileManager.cpp +++ b/stepmania/src/ProfileManager.cpp @@ -129,22 +129,19 @@ bool ProfileManager::LoadProfileFromMemoryCard( PlayerNumber pn ) UnloadProfile( pn ); // mount slot - if( MEMCARDMAN->GetCardState(pn) == MEMORY_CARD_STATE_READY ) - { + if( MEMCARDMAN->GetCardState(pn) != MEMORY_CARD_STATE_READY ) + return false; - CString sDir = MEM_CARD_MOUNT_POINT[pn]; + CString sDir = MEM_CARD_MOUNT_POINT[pn]; - // tack on a subdirectory so that we don't write everything to the root - sDir += PREFSMAN->m_sMemoryCardProfileSubdir; - sDir += '/'; + // tack on a subdirectory so that we don't write everything to the root + sDir += PREFSMAN->m_sMemoryCardProfileSubdir; + sDir += '/'; - bool bSuccess; - bSuccess = LoadProfile( pn, sDir, true ); + bool bSuccess; + bSuccess = LoadProfile( pn, sDir, true ); - return true; // If a card is inserted, we want to use the memory card to save - even if the Profile load failed. - } - - return false; + return true; // If a card is inserted, we want to use the memory card to save - even if the Profile load failed. } bool ProfileManager::LoadFirstAvailableProfile( PlayerNumber pn )