Commit aa0e659d authored by Carola Nitz's avatar Carola Nitz

make VLC compile with Xcode 9.3 beta 2

parent 0561624d
......@@ -27,7 +27,7 @@ class KeychainCoordinator:NSObject, PAPasscodeViewControllerDelegate {
var touchIDEnabled = UserDefaults.standard.bool(forKey:kVLCSettingPasscodeAllowTouchID)
let laContext = LAContext()
if #available(iOS 11.0, *), laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: nil) {
if #available(iOS 11.0.1, *), laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: nil) {
touchIDEnabled = touchIDEnabled && laContext.biometryType == .touchID
}
return touchIDEnabled
......@@ -36,7 +36,7 @@ class KeychainCoordinator:NSObject, PAPasscodeViewControllerDelegate {
var faceIDEnabled = UserDefaults.standard.bool(forKey:kVLCSettingPasscodeAllowFaceID)
let laContext = LAContext()
if #available(iOS 11.0, *), laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: nil) {
if #available(iOS 11.0.1, *), laContext.canEvaluatePolicy(.deviceOwnerAuthenticationWithBiometrics, error: nil) {
faceIDEnabled = faceIDEnabled && laContext.biometryType == .faceID
}
return faceIDEnabled
......
......@@ -175,7 +175,11 @@ static VLCWatchCommunication *_singeltonInstance = nil;
}
- (void)requestThumnail:(VLCWatchMessage *)message {
NSString *uriString = message.payload[VLCWatchMessageKeyURIRepresentation];
NSAssert([message.payload isKindOfClass:[NSDictionary class]], @"the payload needs to be an NSDictionary");
if (![message.payload isKindOfClass:[NSDictionary class]]) return;
NSDictionary *payload = (NSDictionary *)message.payload;
NSString *uriString = payload[VLCWatchMessageKeyURIRepresentation];
NSURL *url = [NSURL URLWithString:uriString];
NSManagedObject *object = [[MLMediaLibrary sharedMediaLibrary] objectForURIRepresentation:url];
if (object) {
......
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