Code Duplication    Length = 6-6 lines in 2 locations

framework/Exceptions/TErrorHandler.php 2 locations

@@ 164-169 (lines=6) @@
161
	{
162
		$aRpl = [];
163
		if ($exception !== null && $exception instanceof \Exception) {
164
			if ($exception instanceof TPhpFatalErrorException &&
165
				function_exists('xdebug_get_function_stack')) {
166
				$aTrace = array_slice(array_reverse(xdebug_get_function_stack()), self::FATAL_ERROR_TRACE_DROP_LINES, -1);
167
			} else {
168
				$aTrace = $exception->getTrace();
169
			}
170
171
			foreach ($aTrace as $item) {
172
				if (isset($item['file'])) {
@@ 376-381 (lines=6) @@
373
	private function getExactTrace($exception)
374
	{
375
		$result = null;
376
		if ($exception instanceof TPhpFatalErrorException &&
377
			function_exists('xdebug_get_function_stack')) {
378
			$trace = array_slice(array_reverse(xdebug_get_function_stack()), self::FATAL_ERROR_TRACE_DROP_LINES, -1);
379
		} else {
380
			$trace = $exception->getTrace();
381
		}
382
383
		// if PHP exception, we want to show the 2nd stack level context
384
		// because the 1st stack level is of little use (it's in error handler)