Mostrar reservas
This commit is contained in:
@ -35,7 +35,7 @@ class Persona extends Ideal\Service
|
||||
/**
|
||||
* @param int $rut
|
||||
* @return Model\Persona
|
||||
* @throws Read|Create
|
||||
* @throws Read
|
||||
*/
|
||||
public function getById(int $rut): Model\Persona
|
||||
{
|
||||
@ -44,7 +44,11 @@ class Persona extends Ideal\Service
|
||||
} catch (Implement\Exception\EmptyResult) {
|
||||
try {
|
||||
$this->propietarioRepository->fetchById($rut);
|
||||
return $this->add(compact('rut'));
|
||||
try {
|
||||
return $this->add(compact('rut'));
|
||||
} catch (Create $exception) {
|
||||
throw new Read(__CLASS__, $exception);
|
||||
}
|
||||
} catch (Implement\Exception\EmptyResult $exception) {
|
||||
throw new Read(__CLASS__, $exception);
|
||||
}
|
||||
|
Reference in New Issue
Block a user