Skip to content

Commit

Permalink
Fix nil error
Browse files Browse the repository at this point in the history
  • Loading branch information
Siedlerchr committed Jun 8, 2021
1 parent b6c4fd6 commit c8657ea
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/ios/PreviewAnyFile.swift
Original file line number Diff line number Diff line change
Expand Up @@ -263,11 +263,6 @@ import CoreServices
let url = myUrl.addingPercentEncoding(withAllowedCharacters:NSCharacterSet.urlQueryAllowed)!;
var itemUrl: URL? = Foundation.URL(string: url);


if !FileManager.default.fileExists(atPath: itemUrl!.path) {
itemUrl = Foundation.URL(string: myUrl);
}

if FileManager.default.fileExists(atPath: itemUrl!.path) {

if(itemUrl?.scheme == nil){
Expand Down Expand Up @@ -332,4 +327,4 @@ extension PreviewAnyFile: QLPreviewControllerDataSource, QLPreviewControllerDele
self.dismissPreviewCallback();

}
}
}

0 comments on commit c8657ea

Please sign in to comment.