Skip to content

Commit eb19233

Browse files
committed
fix: linter and psalm fix
1 parent 0096c3d commit eb19233

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

plugins/hwp-previews/src/Integration/Faust_Integration.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -185,9 +185,11 @@ public function register_faust_admin_notice(): void {
185185
* Check if Faust rewrites are enabled.
186186
*/
187187
public function is_faust_rewrites_enabled(): bool {
188-
return $this->get_faust_enabled()
189-
&& function_exists( '\WPE\FaustWP\Settings\is_rewrites_enabled' )
190-
&& \WPE\FaustWP\Settings\is_rewrites_enabled();
188+
if ( $this->get_faust_enabled() && function_exists( '\WPE\FaustWP\Settings\is_rewrites_enabled' ) ) {
189+
return \WPE\FaustWP\Settings\is_rewrites_enabled();
190+
}
191+
192+
return false;
191193
}
192194

193195
/**
@@ -252,7 +254,7 @@ protected function disable_faust_redirects(): void {
252254
// Remove Faust's redirect callback.
253255
remove_action( 'template_redirect', 'WPE\FaustWP\Deny_Public_Access\deny_public_access', 99 );
254256
}
255-
}, 10 );
257+
}, 10, 0 );
256258
}
257259

258260
/**

0 commit comments

Comments
 (0)