The update checker uses class_exists in several ways: - As a guard clause around `class Whatever` definitions. This ensures we don't try to define a class that has already been loaded by a different plugin. In this case, autoloading is not necessary because we already know how to load the class. Also, we *want to* load our version of that class if possible - the version that gets loaded by somebody else's autoloader might be different and incompatible. - As a guard clause before `require` statements that include a class. This is conceptually the same as the previous example. - To enable optional features if Debug Bar is active. The latest compatible version of Debug Bar doesn't use autoloading, so it would again be unnecessary in this case. |
||
|---|---|---|
| .. | ||
| Parsedown.php | ||
| readme-parser.php | ||