Completed
Push — 0713 ( 6118f2 )
by Mikael
02:49
created

autoload.php (1 issue)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
/**
3
 * Autoloader for CImage and related class files.
4
 *
5
 */
6
//include __DIR__ . "/../CHttpGet.php";
0 ignored issues
show
Unused Code Comprehensibility introduced by
47% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
7
//include __DIR__ . "/../CRemoteImage.php";
8
//include __DIR__ . "/../CImage.php";
9
10
/**
11
 * Autoloader for classes.
12
 *
13
 * @param string $class the fully-qualified class name.
14
 *
15
 * @return void
16
 */
17
spl_autoload_register(function ($class) {
18
    //$path = CIMAGE_SOURCE_PATH . "/{$class}.php";
19
    $path = __DIR__ . "/{$class}.php";
20
    if (is_file($path)) {
21
        require($path);
22
    }
23
});
24