@@ -68,8 +68,6 @@ internal struct MirrorNodeGateway {
6868 let fullApiUrl = MirrorNodeRouter . buildApiUrl (
6969 self . mirrorNodeUrl, MirrorNodeRouter . contractsRoute, idOrAliasOrEvmAddress)
7070
71- print ( " ContractfullApiUrl: \( fullApiUrl) " )
72-
7371 let responseBody = try await queryFromMirrorNode ( fullApiUrl)
7472
7573 guard let jsonData = responseBody. data ( using: . utf8) else {
@@ -89,9 +87,9 @@ internal struct MirrorNodeGateway {
8987 internal func getAccountTokens( _ idOrAliasOrEvmAddress: String ) async throws -> [ String : Any ] {
9088 let fullApiUrl = MirrorNodeRouter . buildApiUrl (
9189 self . mirrorNodeUrl, MirrorNodeRouter . accountTokensRoute, idOrAliasOrEvmAddress)
92-
90+
9391 let responseBody = try await queryFromMirrorNode ( fullApiUrl)
94-
92+
9593 guard let jsonData = responseBody. data ( using: . utf8) else {
9694 throw NSError (
9795 domain: " InvalidResponseError " , code: - 1 ,
@@ -113,10 +111,9 @@ internal struct MirrorNodeGateway {
113111 try ? httpClient. syncShutdown ( )
114112 }
115113
116- var request = HTTPClientRequest ( url: apiUrl)
117- request. method = . GET
114+ let request = HTTPClientRequest ( url: apiUrl)
118115
119- let response = try await httpClient. execute ( request, timeout: . seconds( 30 ) )
116+ let response : HTTPClientResponse = try await httpClient. execute ( request, timeout: . seconds( 30 ) )
120117
121118 let body = try await response. body. collect ( upTo: 1024 * 1024 )
122119 let bodyString = String ( decoding: body. readableBytesView, as: UTF8 . self)
0 commit comments