Skip to content

Commit

Permalink
Avoids launch crash due to DB class dependency. Refs #37.
Browse files Browse the repository at this point in the history
  • Loading branch information
gradha committed Jun 4, 2015
1 parent 372f4e1 commit 1f3f4d9
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions src/App_delegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,6 @@ - (BOOL)application:(UIApplication *)application
{
DLOG(@"Lunching application with %@", launch_options);

SGPS* test = [SGPS get];
[test start];
test.gpsIsOn = YES;
test.saveAllPositions = YES;
#ifdef DEBUG
[self test_swift_migration];
#endif

[[UIDevice currentDevice] setBatteryMonitoringEnabled:YES];
_set_globals();
[DB preserve_old_db];
Expand All @@ -83,6 +75,15 @@ - (BOOL)application:(UIApplication *)application
return NO;
}

SGPS* test = [SGPS get];
[test start];
test.gpsIsOn = YES;
test.saveAllPositions = YES;
#ifdef DEBUG
[self test_swift_migration];
#endif


// For the moment we don't know what to do with this...
if (launch_options)
[db_ log:[NSString stringWithFormat:@"Launch options? %@",
Expand Down

0 comments on commit 1f3f4d9

Please sign in to comment.