Skip to content

Commit

Permalink
Rename getResponseClass to getDataClass
Browse files Browse the repository at this point in the history
  • Loading branch information
loevgaard committed Jun 6, 2024
1 parent 4555bb2 commit 8749f38
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Client/Endpoint/CreatableEndpointTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function create(AbstractDataTransferObject $data): AbstractDataTransferOb
->mapperBuilder
->mapper()
->map(
self::getResponseClass(),
self::getDataClass(),
$this->createSource(
$this->client->post($this->endpoint, $data),
),
Expand Down
2 changes: 1 addition & 1 deletion src/Client/Endpoint/Endpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,5 @@ protected function createSource(ResponseInterface $response): Source
/**
* @return class-string<T>
*/
abstract protected static function getResponseClass(): string;
abstract protected static function getDataClass(): string;
}
2 changes: 1 addition & 1 deletion src/Client/Endpoint/SalesOrderEndpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ final class SalesOrderEndpoint extends Endpoint implements SalesOrderEndpointInt

use DeletableEndpointTrait;

protected static function getResponseClass(): string
protected static function getDataClass(): string
{
return SalesOrder::class;
}
Expand Down

0 comments on commit 8749f38

Please sign in to comment.