Conditions | 2 |
Paths | 2 |
Total Lines | 13 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 9 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
64 | 16 | public static function createBacktraceData ( $backtraceDepth = 0 ) |
|
65 | { |
||
66 | 16 | $backtrace = debug_backtrace( DEBUG_BACKTRACE_IGNORE_ARGS, $backtraceDepth ); |
|
67 | 16 | $backtraceKey = $backtraceDepth - 1; |
|
68 | 16 | if ( isset( $backtrace[ $backtraceKey ][ 'file' ], $backtrace[ $backtraceKey ][ 'line' ] ) ) { |
|
69 | 14 | $parts = [ ]; |
|
70 | 14 | $parts[] = $backtrace[ $backtraceKey ][ 'file' ]; |
|
71 | 14 | $parts[] = $backtrace[ $backtraceKey ][ 'line' ]; |
|
72 | |||
73 | 14 | return $parts; |
|
74 | } |
||
75 | 2 | throw new ErrorException( 'Unable to create BacktraceData.' ); |
|
76 | } |
||
77 | |||
88 |
This check examines a number of code elements and verifies that they conform to the given naming conventions.
You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods.