Illuminate\Routing\Router::formatUsesPrefix PHP Method

formatUsesPrefix() protected static method

Format the uses prefix for the new group attributes.
protected static formatUsesPrefix ( array $new, array $old ) : string | null
$new array
$old array
return string | null
    protected static function formatUsesPrefix($new, $old)
    {
        if (isset($new['namespace'])) {
            return isset($old['namespace']) ? trim($old['namespace'], '\\') . '\\' . trim($new['namespace'], '\\') : trim($new['namespace'], '\\');
        }
        return isset($old['namespace']) ? $old['namespace'] : null;
    }