Skip to content

Commit

Permalink
Fix instance URL in Soap Auth Provider
Browse files Browse the repository at this point in the history
  • Loading branch information
curiosity26 committed Oct 23, 2018
1 parent 441aafb commit bce17a2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/AuthProvider/SoapProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ public function authorize($reauth = false)
$soapBody,
$matches
)) {
$this->instanceUrl = $matches['serverUrl'];
$host = parse_url($matches['serverUrl'], PHP_URL_HOST);
$this->instanceUrl = "https://$host/";
$this->token = $matches['sessionId'];
} else {
throw new SessionExpiredOrInvalidException("Failed to login to Salesforce.", "INVALID_CREDENTIALS");
Expand Down

0 comments on commit bce17a2

Please sign in to comment.