Skip to content

Commit

Permalink
fix: reolve more deprecated warnings
Browse files Browse the repository at this point in the history
Signed-off-by: Ricky Saechao <[email protected]>
  • Loading branch information
RickyLB committed Aug 26, 2024
1 parent a59bd77 commit 3b1dfb5
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Sources/Hedera/Protobufs/FromProtobuf.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ extension TryFromProtobuf {
internal init(protobufBytes bytes: Data) throws where Protobuf: SwiftProtobuf.Message {
let protobuf: Protobuf
do {
protobuf = try Protobuf(contiguousBytes: bytes)
protobuf = try Protobuf(serializedBytes: bytes)
} catch {
throw HError.fromProtobuf("error decoding protobuf bytes: \(error)")
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/HederaTCK/SDKClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ internal class SDKClient {
do {
return Key.single(try PublicKey.fromStringDer(key))
} catch {
return try Key(protobuf: try Proto_Key(serializedData: Data(hex: key)))
return try Key(protobuf: try Proto_Key(serializedBytes: Data(hex: key)))
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion Tests/HederaTests/KeyTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ internal final class KeyTests: XCTestCase {
internal func testFromProtoKeyEcdsa() throws {
let keyBytes = Data(hex: "3a21034e0441201f2bf9c7d9873c2a9dc3fd451f64b7c05e17e4d781d916e3a11dfd99")

let keyProto = try Proto_Key.init(serializedData: keyBytes)
let keyProto = try Proto_Key.init(serializedBytes: keyBytes)

let key = try PublicKey.fromProtobuf(keyProto)

Expand Down

0 comments on commit 3b1dfb5

Please sign in to comment.