Exemplo n.º 1
0
 public function toArray()
 {
     $thrown = $this->hasExceptionBeenThrown();
     $array = parent::toArray();
     $array["success"] = $this->success;
     $array["has_exception_been_thrown"] = $thrown;
     if ($thrown) {
         $array["exception_message"] = $this->getException()->getMessage();
     }
     return $array;
 }
Exemplo n.º 2
0
 public function toArray()
 {
     $array = parent::toArray();
     $array["valid"] = $this->valid;
     return $array;
 }