src/TerminalObject/Router/ExtensionCollection.php
protected function getKey($key, $class)
    {
        if ($key === null || !is_string($key)) {
            $class_path = (is_string($class)) ? $class : get_class($class);

            $key = explode('\\', $class_path);
            $key = end($key);
        }

        return Helper::snakeCase($key);
    }
protected function getKey($key, $class)
    {
        if ($key === null || !is_string($key)) {
            $class_path = (is_string($class)) ? $class : get_class($class);

            $key = explode('\\', $class_path);
            $key = end($key);
        }

        return Helper::snakeCase($key);
    }
protected function getKey ( $ key , $ class ) { if ( $ key === null || ! is_string ( $ key ) ) { $ class_path = ( is_string ( $ class ) ) ? $ class : get_class ( $ class ) ; $ key = explode ( '\\' , $ class_path ) ; $ key = end ( $ key ) ; } return Helper :: snakeCase ( $ key ) ; }
Determine the extension key based on the class

@param string|null $key
@param string|object $class

@return string
Determine the extension key based on the class