code: public function notifyOnError($message, array $backtrace = null, $extraParams = null)
      {
          if (!$backtrace) {
              $backtrace = debug_backtrace();
              if (count($backtrace) > 1) {
                  array_shift($backtrace);
              }
          }
  
          $notice = new Notice;
          $notice->load(array(
              'errorClass'   => 'PHP::Error',
              'backtrace'    => $backtrace,
              'errorMessage' => $message,
              'extraParameters'  => $extraParams,
          ));
  
          return $this->notify($notice);
      }
docs: Notify on an error message.
  
  @param string $message
  @param array $backtrace
  @param null $extraParams
  @return string