]> git.ipfire.org Git - thirdparty/wireguard-apple.git/commitdiff
Importing: Use case-insensitive comparison for zip extension
authorRoopesh Chander <roop@roopc.net>
Mon, 25 Feb 2019 10:46:58 +0000 (16:16 +0530)
committerRoopesh Chander <roop@roopc.net>
Mon, 25 Feb 2019 10:51:29 +0000 (16:21 +0530)
Signed-off-by: Roopesh Chander <roop@roopc.net>
WireGuard/WireGuard/UI/TunnelImporter.swift

index 06148d335a02c0f68f5df8c154521ca130ab6e63..7625761a968dea75976e18d8a70b9373b26ad484 100644 (file)
@@ -5,7 +5,7 @@ import Foundation
 
 class TunnelImporter {
     static func importFromFile(url: URL, into tunnelsManager: TunnelsManager, sourceVC: AnyObject?, errorPresenterType: ErrorPresenterProtocol.Type, completionHandler: (() -> Void)? = nil) {
-        if url.pathExtension == "zip" {
+        if url.pathExtension.lowercased() == "zip" {
             ZipImporter.importConfigFiles(from: url) { result in
                 if let error = result.error {
                     errorPresenterType.showErrorAlert(error: error, from: sourceVC)