AlexanderBuzz / xrpl-php

A PHP library to interact with the XRP Ledger (XRPL) blockchain
ISC License
5 stars 3 forks source link

Error when handling unknown account with autofill - this should be handled #15

Closed zgrguric closed 1 year ago

zgrguric commented 1 year ago
Call to undefined method XRPL_PHP\Models\ErrorResponse::getResult()

  at \vendor\hardcastle\xrpl_php\src\Sugar\autofill.php:93
     89▕     );
     90▕
     91▕     $acoountInfoResponse = $client->request($accountInfoRequest)->wait();
     92▕
  ➜  93▕     $tx['Sequence'] = $acoountInfoResponse->getResult()['account_data']['Sequence'];
     94▕ }
     95▕
     96▕ function fetchAccountDeleteFee (JsonRpcClient $client): BigDecimal
     97▕ {

  1   \vendor\hardcastle\xrpl_php\src\Sugar\autofill.php:184
      XRPL_PHP\Sugar\setNextValidSequenceNumber(Object(XRPL_PHP\Client\JsonRpcClient))

  2   \vendor\hardcastle\xrpl_php\src\Client\JsonRpcClient.php:228
      XRPL_PHP\Sugar\autofill(Object(XRPL_PHP\Client\JsonRpcClient))
AlexanderBuzz commented 1 year ago

This now throws an Exception with the error response text from the server included