diff --git a/src/ET_Client.php b/src/ET_Client.php index b06bbb0..e0d5036 100755 --- a/src/ET_Client.php +++ b/src/ET_Client.php @@ -386,10 +386,10 @@ function createPayloadForOauth2(){ $payload->grant_type = 'client_credentials'; } - if (!empty(trim($this->accountId))){ + if (!empty(trim($this->accountId ?? ''))){ $payload->account_id = $this->accountId; } - if (!empty(trim($this->scope))){ + if (!empty(trim($this->scope ?? ''))){ $payload->scope = $this->scope; }