]> Devoid-pointer.net GitWeb - anyanka.git/commitdiff
Do nothing when user wants to save user data with no runs loaded
authorMichal Malý <madcatxster@prifuk.cz>
Wed, 12 Mar 2014 12:02:14 +0000 (13:02 +0100)
committerMichal Malý <madcatxster@prifuk.cz>
Wed, 12 Mar 2014 12:02:14 +0000 (13:02 +0100)
datamanager.cpp

index 9f4b1bc32dffc29a44d59c5feb4b3eac61b9da30..0428d7c356e060151b4fc9b0e7df16bca1ef6368 100644 (file)
@@ -570,11 +570,12 @@ void DataManager::onLoadSingleRun(const QString& str)
 
 void DataManager::onSaveChanges()
 {
-  std::shared_ptr<SingleRunData> sr = m_activeSequence->selectedRun();
+  std::shared_ptr<SingleRunData> sr;
 
   if (m_activeSequence == nullptr)
     return;
 
+  sr = m_activeSequence->selectedRun();
   sr->saveUserDataToJSON();
 }