From 0061a9daf9564dc8bebd66ae025bb701343da8db Mon Sep 17 00:00:00 2001 From: stoletniy Date: Wed, 15 Nov 2017 12:50:36 +0300 Subject: [PATCH] Move key checks from constructor to init() in Menu class [MAILPOET-1204] --- lib/Config/Menu.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/Config/Menu.php b/lib/Config/Menu.php index 878063db74..87e28b8b1a 100644 --- a/lib/Config/Menu.php +++ b/lib/Config/Menu.php @@ -37,13 +37,14 @@ class Menu { $this->renderer = $renderer; $this->assets_url = $assets_url; $this->access_control = $access_control; + } + + function init() { $subscribers_feature = new SubscribersFeature(); $this->subscribers_over_limit = $subscribers_feature->check(); $this->checkMailPoetAPIKey(); $this->checkPremiumKey(); - } - function init() { add_action( 'admin_menu', array(