PluginProbe
Content Control – The Ultimate Content Restriction Plugin! Restrict Content, Create Conditional Blocks & More / 2.6.1
Content Control – The Ultimate Content Restriction Plugin! Restrict Content, Create Conditional Blocks & More v2.6.1
trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.1.10 1.1.2 1.1.3 1.1.4 1.1.5 1.1.6 1.1.7 1.1.8 2.0.0 2.0.1 2.0.10 2.0.11 2.0.12 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 All 47 releases
← All changes | classes/Controllers/TrustedLogin.php +12 -8 2.0.22.6.1 View file →
@@ -25,10 +25,19 @@
25 25 /**
26 26 * TrustedLogin init.
27 27 */
28 28 public function init() {
29 - $this->hooks();
29 + add_action( 'admin_menu', [ $this, 'admin_menu' ] );
30 + add_action( 'init', [ $this, 'initiate_trustedlogin' ] );
31 + }
30 32
33 + /**
34 + * Hooks.
35 + *
36 + * @return void
37 + */
38 + public function initiate_trustedlogin() {
39 +
31 40 $config = [
32 41 'auth' => [
33 42 'api_key' => 'f97f5be6e02d1565',
34 43 'license_key' => $this->container->get( 'license' )->get_license_key(),
@@ -82,16 +91,11 @@
82 91 }
83 92 }
84 93
85 94 /**
86 - * Hooks.
87 - */
88 - public function hooks() {
89 - add_action( 'admin_menu', [ $this, 'admin_menu' ] );
90 - }
91 -
92 - /**
93 95 * Admin menu.
96 + *
97 + * @return void
94 98 */
95 99 public function admin_menu() {
96 100 // phpcs:ignore WordPress.Security.NonceVerification.Recommended
97 101 if ( ! isset( $_GET['page'] ) || 'grant-content-control-access' !== $_GET['page'] ) {