You are here

protected function TestDefaultExceptionSubscriber::simplifyFileInError in Drupal 8

Same name and namespace in other branches
  1. 9 core/tests/Drupal/Tests/Core/EventSubscriber/FinalExceptionSubscriberTest.php \Drupal\Tests\Core\EventSubscriber\TestDefaultExceptionSubscriber::simplifyFileInError()
  2. 10 core/tests/Drupal/Tests/Core/EventSubscriber/FinalExceptionSubscriberTest.php \Drupal\Tests\Core\EventSubscriber\TestDefaultExceptionSubscriber::simplifyFileInError()

Attempts to reduce error verbosity in the error message's file path.

Attempts to reduce verbosity by removing DRUPAL_ROOT from the file path in the message. This does not happen for (false) security.

Parameters

$error: Optional error to examine for ERROR_REPORTING_DISPLAY_SOME.

Return value

The updated $error.

Overrides FinalExceptionSubscriber::simplifyFileInError

File

core/tests/Drupal/Tests/Core/EventSubscriber/FinalExceptionSubscriberTest.php, line 53

Class

TestDefaultExceptionSubscriber

Namespace

Drupal\Tests\Core\EventSubscriber

Code

protected function simplifyFileInError($error) {
  return $error;
}