| Conditions | 3 |
| Paths | 4 |
| Total Lines | 21 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 72 | public static function require_scope($filename) { |
||
| 73 | |||
| 74 | $return = array(); |
||
| 75 | |||
| 76 | $file = THEME_PATH . 'scope/' . $filename . '.php'; |
||
| 77 | |||
| 78 | if ( file_exists($file) ) { |
||
| 79 | |||
| 80 | require $file; |
||
| 81 | |||
| 82 | } |
||
| 83 | |||
| 84 | if ( isset($data) ) { |
||
| 85 | |||
| 86 | $return = $data; |
||
| 87 | |||
| 88 | } |
||
| 89 | |||
| 90 | return $return; |
||
| 91 | |||
| 92 | } |
||
| 93 | |||
| 94 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.