[ios] Do iosapp token handling in viewDidLoad

Doing this work in viewDidAppear meant that it happened every time the
modal debug settings view disappeared (and the map view reappeared).
This commit is contained in:
Jason Wray
2016-10-28 14:43:25 -07:00
committed by Jason Wray
parent 2242e5484c
commit 300720c8c7

View File

@@ -140,12 +140,7 @@ typedef NS_ENUM(NSInteger, MBXSettingsMiscellaneousRows) {
[self restoreState:nil];
self.debugLoggingEnabled = [[NSUserDefaults standardUserDefaults] boolForKey:@"MGLMapboxMetricsDebugLoggingEnabled"];
}
- (void)viewDidAppear:(BOOL)animated
{
[super viewDidAppear:animated];
if ([MGLAccountManager accessToken].length)
{
self.styleIndex = -1;