Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor Options Parser and default Options Handler (php#110)
* Refactor Options Parser and default Options Handler Refactor default Options Handler to accept dependencies through its constructor. Refactor default Options Handler to return an array of options instead of directly setting options in Config and declare array return types. Refactor method in Options Parser to return an array of options and declare its return type as array. Inject all necessary dependencies in render.php. Refactor two methods in default Options Handler by using match expressions. * Minor refactor of files used in tests Inlcude Config with require_once instead of require in Autloader. Define __INSTALLDIR__ only if it is not defined yet in render.php. Include Autoloader and functions.php with require_once instead of require. Remove unnecessary __PHPDIR__ constant, correct path for __INSTALLDIR__ and use that constant in setup.php. * Remove var_dump from Options Parser * Fix inconsistent option flags in default Option Handler * Add default Options Handler tests --------- Co-authored-by: haszi <[email protected]>
- Loading branch information