[orca/new-settings] Provide default profile as a fallback when saveSettings is attempted but no provile yet exists.



commit d7b7619dcfac30f017c6c01db3909cd22b4f8c17
Author: Joanmarie Diggs <joanmarie diggs gmail com>
Date:   Thu Oct 28 13:41:18 2010 -0400

    Provide default profile as a fallback when saveSettings is attempted but no provile yet exists.

 src/orca/settings_manager.py |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/orca/settings_manager.py b/src/orca/settings_manager.py
index 594a908..3fa7a21 100644
--- a/src/orca/settings_manager.py
+++ b/src/orca/settings_manager.py
@@ -286,7 +286,9 @@ class SettingsManager():
         """Let the active backend to store the default settings and
         the profiles' ones."""
         # Assign current profile
-        (currentProfileString, currentProfile) = general.get('profile')
+        (currentProfileString, currentProfile) = \
+            general.get('profile', ['Default', 'default'])
+
         self.profile = currentProfile
 
         # The default settings should already exist but we save them anyway



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]