private function addHelper(string $name, string $path): void
    {
        $class = static::class;

        // create store of helpers for this class
        if (!isset(static::$helpers[$class])) {
            static::$helpers[$class] = [];
        }

        $helper = include $path;

        if (\is_callable($helper)) {
            static::$helpers[$class][$name] = $helper;
        } else {
            throw new CommonException("Helper `$name` not found in file `$path`");
        }
    }
private function addHelper(string $name, string $path): void
    {
        $class = static::class;

        // create store of helpers for this class
        if (!isset(static::$helpers[$class])) {
            static::$helpers[$class] = [];
        }

        $helper = include $path;

        if (\is_callable($helper)) {
            static::$helpers[$class][$name] = $helper;
        } else {
            throw new CommonException("Helper `$name` not found in file `$path`");
        }
    }
private function addHelper ( string $ name , string $ path ) : void { $ class = static :: class ; // create store of helpers for this class if ( ! isset ( static :: $ helpers [ $ class ] ) ) { static :: $ helpers [ $ class ] = [ ] ; } $ helper = include $ path ; if ( \ is_callable ( $ helper ) ) { static :: $ helpers [ $ class ] [ $ name ] = $ helper ; } else { throw new CommonException ( "Helper `$name` not found in file `$path`" ) ; } }
Add helper callable

@param  string $name
@param  string $path

@return void
@throws CommonException
Add helper callable