Skip to content

Commit

Permalink
chore: error message fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JeneaVranceanu committed Nov 3, 2023
1 parent cfd8ee9 commit 0b0b3fa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/web3swift/Utils/EIP/EIP712/EIP712Parser.swift
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ public struct EIP712TypedData {

public func encodeType(_ type: String) throws -> String {
guard let typeData = types[type] else {
throw Web3Error.processingError(desc: "EIP712Parser. Attempting to encode type that doesn't exist in this payload. Given type: \(type). Available types: \(types.values).")
throw Web3Error.processingError(desc: "EIP712Parser. Attempting to encode type that doesn't exist in this payload. Given type: \(type). Available types: \(types.keys).")
}
return try encodeType(type, typeData)
}
Expand Down Expand Up @@ -216,7 +216,7 @@ public struct EIP712TypedData {
var encValues: [Any] = [try typeHash(type)]

guard let typeData = types[type] else {
throw Web3Error.processingError(desc: "EIP712Parser. Attempting to encode data for type that doesn't exist in this payload. Given type: \(type). Available types: \(types.values).")
throw Web3Error.processingError(desc: "EIP712Parser. Attempting to encode data for type that doesn't exist in this payload. Given type: \(type). Available types: \(types.keys).")
}

func encodeField(_ field: EIP712TypeProperty,
Expand Down

0 comments on commit 0b0b3fa

Please sign in to comment.