updated plugin WP Mail SMTP
version 2.0.0
This commit is contained in:
@ -18,6 +18,7 @@
|
||||
namespace Google\Auth\Subscriber;
|
||||
|
||||
use Google\Auth\FetchAuthTokenInterface;
|
||||
use Google\Auth\GetQuotaProjectInterface;
|
||||
use GuzzleHttp\Event\BeforeEvent;
|
||||
use GuzzleHttp\Event\RequestEvents;
|
||||
use GuzzleHttp\Event\SubscriberInterface;
|
||||
@ -114,5 +115,19 @@ class AuthTokenSubscriber implements SubscriberInterface
|
||||
call_user_func($this->tokenCallback, $this->fetcher->getCacheKey(), $auth_tokens['access_token']);
|
||||
}
|
||||
}
|
||||
|
||||
if ($quotaProject = $this->getQuotaProject()) {
|
||||
$request->setHeader(
|
||||
GetQuotaProjectInterface::X_GOOG_USER_PROJECT_HEADER,
|
||||
$quotaProject
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
private function getQuotaProject()
|
||||
{
|
||||
if ($this->fetcher instanceof GetQuotaProjectInterface) {
|
||||
return $this->fetcher->getQuotaProject();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user