routeros-api-php icon indicating copy to clipboard operation
routeros-api-php copied to clipboard

How to handle response error properly?

Open fikurimax opened this issue 1 year ago • 0 comments

Is there a proper way to handle error? as for now I handle error by using this way

$response = $client->qr($query);
if (isset($response['after']['message']) {}

because I get this 'after' key when i get response error such as no such commands error

fikurimax avatar Aug 10 '23 01:08 fikurimax