protected function getPasswordEncoder($userData = null)
    {
        if (isset($userData['encoder']) && is_string($userData['encoder'])) {
            $name = $userData['encoder'];
        } else {
            $name = $this->config["encoder"];
        }

        $container = $this->picoAuth->getContainer();
        
        if (!$container->has($name)) {
            throw new \RuntimeException("Specified LocalAuth encoder is not resolvable.");
        }

        return $container->get($name);
    }
protected function getPasswordEncoder($userData = null)
    {
        if (isset($userData['encoder']) && is_string($userData['encoder'])) {
            $name = $userData['encoder'];
        } else {
            $name = $this->config["encoder"];
        }

        $container = $this->picoAuth->getContainer();
        
        if (!$container->has($name)) {
            throw new \RuntimeException("Specified LocalAuth encoder is not resolvable.");
        }

        return $container->get($name);
    }
protected function getPasswordEncoder ( $ userData = null ) { if ( isset ( $ userData [ 'encoder' ] ) && is_string ( $ userData [ 'encoder' ] ) ) { $ name = $ userData [ 'encoder' ] ; } else { $ name = $ this -> config [ "encoder" ] ; } $ container = $ this -> picoAuth -> getContainer ( ) ; if ( ! $ container -> has ( $ name ) ) { throw new \ RuntimeException ( "Specified LocalAuth encoder is not resolvable." ) ; } return $ container -> get ( $ name ) ; }
Returns encoder instance for the specified user

If the user data array is not specified, returns the default
encoder instance.

@param null|array $userData User data array
@return \PicoAuth\Security\Password\Encoder\PasswordEncoderInterface
@throws \RuntimeException If the encoder is not resolvable
Returns encoder instance for the specified user