lithium\core\ErrorHandler::_origin PHP Method

_origin() protected static method

Determine frame from the stack trace where the error/exception was first generated.
protected static _origin ( array $stack ) : string
$stack array Stack trace from error/exception that was produced.
return string Class where error/exception was generated.
    protected static function _origin(array $stack)
    {
        foreach ($stack as $frame) {
            if (isset($frame['class'])) {
                return trim($frame['class'], '\\');
            }
        }
    }