diff --git a/astrid/.classpath b/astrid/.classpath index 5e1a35c02..3e5239912 100644 --- a/astrid/.classpath +++ b/astrid/.classpath @@ -15,8 +15,8 @@ - + diff --git a/astrid/src/com/todoroo/astrid/service/StartupService.java b/astrid/src/com/todoroo/astrid/service/StartupService.java index 30436041e..28225760c 100644 --- a/astrid/src/com/todoroo/astrid/service/StartupService.java +++ b/astrid/src/com/todoroo/astrid/service/StartupService.java @@ -107,7 +107,13 @@ public class StartupService { } // read current version - int latestSetVersion = AstridPreferences.getCurrentVersion(); + int latestSetVersion = 0; + try { + latestSetVersion = AstridPreferences.getCurrentVersion(); + } catch (Exception e) { + exceptionService.reportError("astrid-startup-version-read", e); //$NON-NLS-1$ + } + int version = 0; try { PackageManager pm = context.getPackageManager(); diff --git a/astrid/src/com/todoroo/astrid/utility/AstridPreferences.java b/astrid/src/com/todoroo/astrid/utility/AstridPreferences.java index bd5c42ce4..44ba6f489 100644 --- a/astrid/src/com/todoroo/astrid/utility/AstridPreferences.java +++ b/astrid/src/com/todoroo/astrid/utility/AstridPreferences.java @@ -49,11 +49,7 @@ public class AstridPreferences { /** CurrentVersion: the currently installed version of Astrid */ public static int getCurrentVersion() { - try { - return Preferences.getInt(P_CURRENT_VERSION, 0); - } catch (Exception e) { - return 0; - } + return Preferences.getInt(P_CURRENT_VERSION, 0); } /** CurrentVersion: the currently installed version of Astrid */