Rework subscriber count reporting after a code review [MAILPOET-804]
Move updateSubscriberCount() out of checkKey() Move wp_remote_post() to request() Simplify a response check
This commit is contained in:
@ -88,6 +88,7 @@ class SendingServiceKeyCheck {
|
||||
try {
|
||||
$mailer_config = Mailer::getMailerConfig();
|
||||
$result = $this->bridge->checkKey($mailer_config['mailpoet_api_key']);
|
||||
$this->bridge->updateSubscriberCount($result);
|
||||
} catch (\Exception $e) {
|
||||
$result = false;
|
||||
}
|
||||
|
Reference in New Issue
Block a user