Browse Source

Refactored ServerTrustPolicy APIs to use `in` instead of `within` where applicable.

Christian Noon 9 years ago
parent
commit
6c5ac3296e
1 changed files with 3 additions and 3 deletions
  1. 3 3
      Source/ServerTrustPolicy.swift

+ 3 - 3
Source/ServerTrustPolicy.swift

@@ -119,7 +119,7 @@ public enum ServerTrustPolicy {
     /// - parameter bundle: The bundle to search for all `.cer` files.
     ///
     /// - returns: All certificates within the given bundle.
-    public static func certificates(within bundle: Bundle = Bundle.main) -> [SecCertificate] {
+    public static func certificates(in bundle: Bundle = Bundle.main) -> [SecCertificate] {
         var certificates: [SecCertificate] = []
 
         let paths = Set([".cer", ".CER", ".crt", ".CRT", ".der", ".DER"].map { fileExtension in
@@ -143,10 +143,10 @@ public enum ServerTrustPolicy {
     /// - parameter bundle: The bundle to search for all `*.cer` files.
     ///
     /// - returns: All public keys within the given bundle.
-    public static func publicKeys(within bundle: Bundle = Bundle.main) -> [SecKey] {
+    public static func publicKeys(in bundle: Bundle = Bundle.main) -> [SecKey] {
         var publicKeys: [SecKey] = []
 
-        for certificate in certificates(within: bundle) {
+        for certificate in certificates(in: bundle) {
             if let publicKey = publicKey(for: certificate) {
                 publicKeys.append(publicKey)
             }