diff --git a/app/src/Service/Venta/Cuota.php b/app/src/Service/Venta/Cuota.php index 8f022ca..9735701 100644 --- a/app/src/Service/Venta/Cuota.php +++ b/app/src/Service/Venta/Cuota.php @@ -75,10 +75,11 @@ class Cuota } public function getByPie(int $pie_id): array { - return $this->cuotaRepository->fetchByPie($pie_id); - /*return array_filter($this->cuotaRepository->fetchByPie($pie_id), function(Model\Venta\Cuota $cuota) { - return !in_array($cuota->pago->currentEstado->tipoEstadoPago->descripcion, ['anulado']); - });*/ + try { + return $this->cuotaRepository->fetchByPie($pie_id); + } catch (EmptyResult) { + return []; + } } public function getVigenteByPie(int $pie_id): array {