Commit 7fcba87b authored by Felix Paul Kühne's avatar Felix Paul Kühne

Remove legacy passcode conversation code and add missing return

parent affbd146
......@@ -3,6 +3,7 @@
* Stability improvements
* Improved HTTP connectivity
* Improved UPnP reliability, notably with Twonky
* Fixed issues unlocking the app when a passcode was never set
2.7.1:
------
......
......@@ -61,8 +61,7 @@ NSString *const VLCDropboxSessionWasAuthorized = @"VLCDropboxSessionWasAuthorize
else
skipLoopFilterDefaultValue = kVLCSettingSkipLoopFilterNonRef;
NSDictionary *appDefaults = @{kVLCSettingPasscodeKey : @"",
kVLCSettingPasscodeAllowTouchID : @(1),
NSDictionary *appDefaults = @{kVLCSettingPasscodeAllowTouchID : @(1),
kVLCSettingContinueAudioInBackgroundKey : @(YES),
kVLCSettingStretchAudio : @(NO),
kVLCSettingTextEncoding : kVLCSettingTextEncodingDefaultValue,
......
......@@ -13,7 +13,6 @@
#define kVLCVersionCodename @"All Along the Watchtower"
#define kVLCSettingPasscodeKey @"Passcode"
#define kVLCSettingPasscodeOnKey @"PasscodeProtection"
#define kVLCSettingPasscodeAllowTouchID @"AllowTouchID"
#define kVLCSettingContinueAudioInBackgroundKey @"BackgroundAudioPlayback"
......
......@@ -77,20 +77,6 @@ NSString *const VLCPasscode = @"org.videolan.vlc-ios.passcode";
- (NSString *)_obtainPasscode
{
NSString *passcode = [SSKeychain passwordForService:VLCPasscode account:VLCPasscode];
if (!passcode) {
/* legacy passcode conversion to keychain - only do that once */
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
passcode = [defaults objectForKey:kVLCSettingPasscodeKey];
if (passcode && passcode.length > 0) {
APLog(@"Move passcode from setting to keychain");
[self setPasscode:passcode];
// delete passcode from old setting
[defaults removeObjectForKey:kVLCSettingPasscodeKey];
[defaults synchronize];
}
}
return passcode;
}
......@@ -117,6 +103,7 @@ NSString *const VLCPasscode = @"org.videolan.vlc-ios.passcode";
NSString *passcode = [self _obtainPasscode];
if (passcode == nil || [passcode isEqualToString:@""]) {
[[NSNotificationCenter defaultCenter] postNotificationName:VLCPasscodeValidated object:self];
return;
}
_passcodeLockController = [[PAPasscodeViewController alloc] initForAction:PasscodeActionEnter];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment