public function handleError($app, $errno, $message, $file, $line) { $aError = compact('errno', 'message', 'file', 'line'); Pico::cfg()->use_debug_mail and dbgmail(print_r($aError, true), Pico::cfg()->admin_email); Pico::cfg()->use_debug_log and dbglogr($aError); return $this->error($app, $aError, PICOWA_DEBUG_MODE); }
public function handleException($app, $exception) { $aError = array('type' => get_class($exception), 'code' => $exception->getCode(), 'message' => $exception->getMessage(), 'file' => $exception->getFile(), 'line' => $exception->getLine()); Pico::cfg()->use_debug_mail and dbgmail(print_r($aError, true), Pico::cfg()->admin_email); Pico::cfg()->use_debug_log and dbglogr($aError); $aError['trace'] = $exception->getTraceAsString(); return $this->error($app, $aError, PICOWA_DEBUG_MODE); }