refactor(fer-19) : url de base unique pour le pont-bascule
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -15,7 +15,7 @@ final class PontBasculeService
|
||||
public function __construct(
|
||||
private readonly HttpClientInterface $httpClient,
|
||||
private readonly PontBasculePayloadDecoder $payloadDecoder,
|
||||
private readonly string $endpoint,
|
||||
private readonly string $baseUrl,
|
||||
private readonly bool $bypass,
|
||||
) {}
|
||||
|
||||
@@ -28,7 +28,7 @@ final class PontBasculeService
|
||||
$body = $this->getBypassPayload();
|
||||
} else {
|
||||
try {
|
||||
$response = $this->httpClient->request('POST', $this->endpoint);
|
||||
$response = $this->httpClient->request('POST', $this->baseUrl.'/send/dsd');
|
||||
$body = $response->getContent(false);
|
||||
} catch (TransportExceptionInterface $exception) {
|
||||
throw PontBasculeException::transportFailure($exception->getMessage());
|
||||
|
||||
Reference in New Issue
Block a user