Skip to content

Commit

Permalink
chore: clean up call with base url
Browse files Browse the repository at this point in the history
  • Loading branch information
ju5t committed Jun 14, 2024
1 parent efdbe2a commit 7c851e2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/DirectAdmin.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,11 @@ public function call(string $command, array $params = [], Method $method = Metho

try {
$response = Http::acceptJson()
->baseUrl($this->server)
->withBasicAuth($this->username, $this->password)
->withOptions($this->getHttpOptions())
->withQueryParameters($this->getQueryParams())
->{$method->verb()}($this->server.'/'.$command, $params);
->{$method->verb()}($command, $params);
} catch (ConnectionException $e) {
throw ConnectionFailed::create($e->getMessage());
}
Expand Down

0 comments on commit 7c851e2

Please sign in to comment.