some method annotation corrections, and minor settings page typoes

isekai
Jonathan Daggerhart 8 years ago
parent 54c43eb2b9
commit 14133138a7

@ -23,6 +23,7 @@ class OpenID_Connect_Generic_Client_Wrapper {
/**
* Inject necessary objects and services into the client
*
* @param \OpenID_Connect_Generic_Client $client
* @param \WP_Option_Settings $settings
* @param \WP_Option_Logger $logger
*/
@ -368,7 +369,8 @@ class OpenID_Connect_Generic_Client_Wrapper {
if ( ! $user ) {
$user = $this->create_new_user( $subject_identity, $user_claim );
if ( is_wp_error( $user ) ) {
return $this->error_redirect( $user );
$this->error_redirect( $user );
return;
}
}
else {
@ -408,7 +410,7 @@ class OpenID_Connect_Generic_Client_Wrapper {
*
* @param $user
*
* @return \WP_Error
* @return true|\WP_Error
*/
function validate_user( $user ){
// ensure our found user is a real WP_User
@ -689,7 +691,7 @@ class OpenID_Connect_Generic_Client_Wrapper {
$username = $_username;
}
$_nickname = $this->get_nickname_from_claim( $user_claim, true );
$_nickname = $this->get_nickname_from_claim( $user_claim );
if ( is_wp_error( $_nickname ) ) {
$values_missing = true;
} else if ( $_nickname !== null) {
@ -729,7 +731,7 @@ class OpenID_Connect_Generic_Client_Wrapper {
$username = $_username;
}
$_nickname = $this->get_nickname_from_claim( $user_claim, true );
$_nickname = $this->get_nickname_from_claim( $user_claim );
if ( is_wp_error( $_nickname ) ) {
return $_nickname;
} else if ( $_nickname === null) {

@ -58,7 +58,7 @@ class OpenID_Connect_Generic_Client {
*
* @param $request
*
* @return \WP_Error
* @return array|\WP_Error
*/
function validate_authentication_request( $request ){
// look for an existing error of some kind
@ -82,7 +82,9 @@ class OpenID_Connect_Generic_Client {
/**
* Get the authorization code from the request
*
* @return string
* @param $request array
*
* @return string|\WP_Error
*/
function get_authentication_code( $request ){
return $request['code'];
@ -386,6 +388,8 @@ class OpenID_Connect_Generic_Client {
/**
* Retrieve the subject identity from the id_token
*
* @param $id_token_claim array
*
* @return mixed
*/
function get_subject_identity( $id_token_claim ){

@ -147,7 +147,7 @@ class OpenID_Connect_Generic_Settings_Page {
),
'identify_with_username' => array(
'title' => __( 'Identify with User Name' ),
'description' => __( 'If checked, the user\' identity will be determined by the user name instead of the email address.' ),
'description' => __( 'If checked, the user\'s identity will be determined by the user name instead of the email address.' ),
'type' => 'checkbox',
'section' => 'client_settings',
),
@ -159,7 +159,7 @@ class OpenID_Connect_Generic_Settings_Page {
),
'redirect_user_back' => array(
'title' => __( 'Redirect Back to Origin Page' ),
'description' => __( 'After a successful OpenID Connect authentication, this will <strong>override the default action of redirecting the user to the home page and instead redirect the user back to the page on which they clicked the OpenID Connect login button</strong>. This will cause the login process to proceed in a traditional WordPress fashion. For example, users logging in through the default wp-login.php page would end up on the WordPress Dashboard and users logging in through the WooCommerce "My Account" page would end up on their account page.' ),
'description' => __( 'After a successful OpenID Connect authentication, this will redirect the user back to the page on which they clicked the OpenID Connect login button. This will cause the login process to proceed in a traditional WordPress fashion. For example, users logging in through the default wp-login.php page would end up on the WordPress Dashboard and users logging in through the WooCommerce "My Account" page would end up on their account page.' ),
'type' => 'checkbox',
'section' => 'user_settings',
),

Loading…
Cancel
Save