Prado\Exceptions\TErrorHandler::getExactTrace PHP Method

getExactTrace() private method

private getExactTrace ( $exception )
    private function getExactTrace($exception)
    {
        $trace = $exception->getTrace();
        $result = null;
        // if PHP exception, we want to show the 2nd stack level context
        // because the 1st stack level is of little use (it's in error handler)
        if ($exception instanceof TPhpErrorException) {
            if (isset($trace[0]['file'])) {
                $result = $trace[0];
            } elseif (isset($trace[1])) {
                $result = $trace[1];
            }
        } else {
            if ($exception instanceof TInvalidOperationException) {
                // in case of getter or setter error, find out the exact file and row
                if (($result = $this->getPropertyAccessTrace($trace, '__get')) === null) {
                    $result = $this->getPropertyAccessTrace($trace, '__set');
                }
            }
        }
        if ($result !== null && strpos($result['file'], ': eval()\'d code') !== false) {
            return null;
        }
        return $result;
    }