Browse Source

Fix Swift 5 warning

With Swift 5 the bytes initializer is deprecated. The replacement is
backwards compatible
Keith Smiley 6 năm trước cách đây
mục cha
commit
20e35a06a1
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      Sources/CryptoSwift/Foundation/Data+Extension.swift

+ 1 - 1
Sources/CryptoSwift/Foundation/Data+Extension.swift

@@ -82,7 +82,7 @@ extension Data {
 
 extension Data {
     public init(hex: String) {
-        self.init(bytes: Array<UInt8>(hex: hex))
+        self.init(Array<UInt8>(hex: hex))
     }
 
     public var bytes: Array<UInt8> {