- Catching exceptions improved
- Made classes dependent to each other
You can trace the error by catching DebugException class.
<?php
$payme = new Api();
$payme->setCredentials(['login' => 'paymega ulangan telefon raqam (Telefon raqam 901234565 formatda bo`lishi kerak)', 'password' => 'paymedagi parol']);
try {
foreach ($payme->selectCard('card id')->findByComment('comment', 0) as $e) {
echo $e->getCard()->getTitle();
}
} catch (\App\Payme\DebugException $e) {
echo $e->getExceptionMessage();
die;
}