src/Grant/GrantFactory.php
protected function registerDefaultGrant($name)
    {
        // PascalCase the grant. E.g: 'authorization_code' becomes 'AuthorizationCode'
        $class = str_replace(' ', '', ucwords(str_replace(['-', '_'], ' ', $name)));
        $class = 'League\\OAuth2\\Client\\Grant\\' . $class;

        $this->checkGrant($class);

        return $this->setGrant($name, new $class);
    }
protected function registerDefaultGrant($name)
    {
        // PascalCase the grant. E.g: 'authorization_code' becomes 'AuthorizationCode'
        $class = str_replace(' ', '', ucwords(str_replace(['-', '_'], ' ', $name)));
        $class = 'League\\OAuth2\\Client\\Grant\\' . $class;

        $this->checkGrant($class);

        return $this->setGrant($name, new $class);
    }
protected function registerDefaultGrant ( $ name ) { // PascalCase the grant. E.g: 'authorization_code' becomes 'AuthorizationCode' $ class = str_replace ( ' ' , '' , ucwords ( str_replace ( [ '-' , '_' ] , ' ' , $ name ) ) ) ; $ class = 'League\\OAuth2\\Client\\Grant\\' . $ class ; $ this -> checkGrant ( $ class ) ; return $ this -> setGrant ( $ name , new $ class ) ; }
Registers a default grant singleton by name.

@param  string $name
@return self
Registers a default grant singleton by name .