albertlast /
SMF2.1
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
| 1 | <?php |
||
| 2 | |||
| 3 | /** |
||
| 4 | * This file is here solely to protect your avatars directory. |
||
| 5 | */ |
||
| 6 | |||
| 7 | // Look for Settings.php.... |
||
| 8 | View Code Duplication | if (file_exists(dirname(dirname(__FILE__)) . '/Settings.php')) |
|
|
0 ignored issues
–
show
|
|||
| 9 | { |
||
| 10 | // Found it! |
||
| 11 | require(dirname(dirname(__FILE__)) . '/Settings.php'); |
||
| 12 | header('Location: ' . $boardurl); |
||
| 13 | } |
||
| 14 | // Can't find it... just forget it. |
||
| 15 | else |
||
| 16 | exit; |
||
| 17 | |||
| 18 | ?> |
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.