Skip to content

Commit f1bb049

Browse files
authored
fix warnings pointed by phpstan
1 parent aaf1975 commit f1bb049

5 files changed

Lines changed: 6 additions & 5 deletions

File tree

plugins/bcc-keep-translated-posts-status-same-as-original/includes/class-bcc-keep-translated-posts-status-same-as-original-updater.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ public function update( $transient ) {
153153

154154
}
155155

156-
public function purge(){
156+
public function purge( $upgrader_object, $options ){
157157

158158
if (
159159
$this->cache_allowed

plugins/bcc-login/includes/class-bcc-login-client.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,8 @@ function create_new_user( $person_id, $email, $id_token_claims ) {
204204
'user_email' => $email,
205205
'display_name' => $displayname,
206206
'nickname' => $nickname,
207-
'first_name' => isset( $user_claim['given_name'] ) ? $user_claim['given_name'] : '',
208-
'last_name' => isset( $user_claim['family_name'] ) ? $user_claim['family_name'] : '',
207+
'first_name' => isset( $id_token_claims['given_name'] ) ? $id_token_claims['given_name'] : '',
208+
'last_name' => isset( $id_token_claims['family_name'] ) ? $id_token_claims['family_name'] : '',
209209
);
210210

211211
// Create the new user.

plugins/bcc-login/includes/class-bcc-login-endpoints.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function __construct( BCC_Login_Settings $settings ) {
99

1010
add_action( 'init', array( $this, 'add_rewrite_rules' ) );
1111
add_filter( 'query_vars', array( $this, 'add_query_vars' ) );
12-
add_action( 'template_include', array( $this, 'include_endpoint' ), 99 );
12+
add_filter( 'template_include', array( $this, 'include_endpoint' ), 99 );
1313
}
1414

1515
/**

plugins/bcc-login/includes/class-bcc-login-updater.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ public function update( $transient ) {
157157

158158
}
159159

160-
public function purge(){
160+
public function purge( $upgrader_object, $options ){
161161

162162
if (
163163
$this->cache_allowed

plugins/bcc-login/includes/class-bcc-login-visibility.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -628,6 +628,7 @@ function filter_pre_get_posts( $query ) {
628628

629629
// Set the meta query to the complete, altered query
630630
$query->set('meta_query', $meta_query);
631+
return;
631632
}
632633

633634
/**

0 commit comments

Comments
 (0)