Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Commit

Permalink
CS
Browse files Browse the repository at this point in the history
  • Loading branch information
sanmai committed Nov 9, 2019
1 parent 122ba8e commit a31679a
Show file tree
Hide file tree
Showing 15 changed files with 1 addition and 55 deletions.
9 changes: 0 additions & 9 deletions src/CdekClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -217,11 +217,6 @@ public function __call(string $name, array $arguments)
* @psalm-suppress LessSpecificReturnStatement
* @psalm-suppress ArgumentTypeCoercion
* @psalm-suppress MoreSpecificReturnType
*
* @param Request $request
* @param ResponseInterface $response
*
* @return Response
*/
private function deserialize(Request $request, ResponseInterface $response): Response
{
Expand Down Expand Up @@ -285,10 +280,6 @@ private function serialize(XmlRequest $request): string

/**
* @see \CdekSDK\Requests\Concerns\Authorized::$date
*
* @param \DateTimeInterface $date
*
* @return string
*/
private function getSecure(\DateTimeInterface $date): string
{
Expand Down
2 changes: 0 additions & 2 deletions src/Common/AdditionalService.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,6 @@ public function getSum(): float
* @see AdditionalService::SERVICE_DOCUMENTS_COPY
* @see AdditionalService::SERVICE_PARTIAL_DELIVERY
* @see AdditionalService::SERVICE_CARGO_CHECK
*
* @return self
*/
public static function create($codeOrData): self
{
Expand Down
6 changes: 0 additions & 6 deletions src/Common/CallCourier.php
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,6 @@ final class CallCourier implements HasErrorCode

/**
* Устанавливает адрес в целях регистрация заявки на вызов курьера.
*
* @param Address $address
*/
public function setAddress(Address $address): self
{
Expand All @@ -212,10 +210,6 @@ public function setAddress(Address $address): self

/**
* Устанавливает адрес в заявке на вызов курьера при регистрации заказа.
*
* @param Address $address
*
* @return self
*/
public function setSendAddress(Address $address): self
{
Expand Down
4 changes: 1 addition & 3 deletions src/Common/Fillable.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,7 @@ public function __construct(array $data = [])
foreach ($data as $key => $value) {
if (!\property_exists($this, $key)) {
/** @phan-suppress-next-line PhanTypeInstantiateTraitStaticOrSelf */
throw new \InvalidArgumentException(\sprintf(
'The class "%s" does not have the property "%s"', static::class, $key
));
throw new \InvalidArgumentException(\sprintf('The class "%s" does not have the property "%s"', static::class, $key));
}

$this->{$key} = $value;
Expand Down
2 changes: 0 additions & 2 deletions src/Common/Location.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,6 @@ public function getCountry(): string
/**
* @deprecated СДЭК перешли на использование буквенных кодов стран в начале 2019 года
* @see Location::getCountryCodeISO()
*
* @return int
*/
public function getCountryCode(): int
{
Expand Down
8 changes: 0 additions & 8 deletions src/Common/Order.php
Original file line number Diff line number Diff line change
Expand Up @@ -668,8 +668,6 @@ public function getDispatchNumber(): string

/**
* Возвращает идентификатор заказа для API СДЭК, который состоит либо из DispatchNumber, либо из параметров Number, Date. Запросы по заказам должны включать эти параметры для идентификации заказа.
*
* @return string
*/
public function getId(): string
{
Expand Down Expand Up @@ -765,8 +763,6 @@ public function getComment(): string
* @phan-suppress PhanDeprecatedProperty
*
* @deprecated
*
* @return string
*/
public function getSellerName(): string
{
Expand Down Expand Up @@ -929,8 +925,6 @@ public function getCall(): Call

/**
* @throws \TypeError
*
* @return Order
*/
public function getReturnOrder(): Order
{
Expand All @@ -954,8 +948,6 @@ public function getDeliveryDate()
* Номер возвратной накладной.
*
* @todo возвращать строку, как для других номеров отправлений
*
* @return int
*/
public function getReturnDispatchNumber(): int
{
Expand Down
4 changes: 0 additions & 4 deletions src/Common/WorkTime.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ final class WorkTime

/**
* Порядковый номер дня начиная с единицы. Понедельник = 1, воскресенье = 7.
*
* @return int
*/
public function getDay(): int
{
Expand All @@ -67,8 +65,6 @@ public function getDay(): int

/**
* Период работы в этот день.
*
* @return string
*/
public function getPeriods(): string
{
Expand Down
2 changes: 0 additions & 2 deletions src/Requests/CalculationAuthorizedRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@ class CalculationAuthorizedRequest extends Templates\CalculationAuthorizedReques
/**
* @deprecated
* @phan-suppress PhanDeprecatedClass
*
* @return CalculationAuthorizedRequest
*/
public static function withAuthorization(): CalculationAuthorizedRequest
{
Expand Down
3 changes: 0 additions & 3 deletions src/Responses/CalculationResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ final class CalculationResponse implements Response
*/
private $errors = [];

/**
* @return bool
*/
public function hasErrors(): bool
{
return !empty($this->errors);
Expand Down
3 changes: 0 additions & 3 deletions src/Responses/CalculationWithTariffListResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,6 @@ final class CalculationWithTariffListResponse implements Response, \IteratorAggr
*/
private $errors = [];

/**
* @return bool
*/
public function hasErrors(): bool
{
return !empty($this->errors);
Expand Down
3 changes: 0 additions & 3 deletions src/Responses/Concerns/WithTraceId.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@ trait WithTraceId
*/
protected $TraceId = '';

/**
* @return string
*/
final public function getTraceId(): string
{
return $this->TraceId;
Expand Down
1 change: 0 additions & 1 deletion src/Responses/Types/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ final class Message implements HasErrorCode
private $errorCode;

/**
* @param string $text
* @param string|null $errorCode
*/
public function __construct(string $text, $errorCode = null)
Expand Down
3 changes: 0 additions & 3 deletions src/Responses/Types/Result.php
Original file line number Diff line number Diff line change
Expand Up @@ -207,9 +207,6 @@ public function getAdditionalServices()
return $this->services;
}

/**
* @return bool
*/
public function hasErrors(): bool
{
return $this->error !== null;
Expand Down
3 changes: 0 additions & 3 deletions src/Responses/Types/TariffResult.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,6 @@ final class TariffResult implements Response
*/
private $status;

/**
* @return bool
*/
public function hasErrors(): bool
{
return $this->result->hasErrors();
Expand Down
3 changes: 0 additions & 3 deletions tests/Integration/DebuggingLogger.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ final class DebuggingLogger implements LoggerInterface
/**
* @param mixed $level
* @param string $message
* @param array $context
*
* @psalm-suppress MixedTypeCoercion
*/
Expand Down Expand Up @@ -78,8 +77,6 @@ private static function getLogFileHandle()

/**
* @param array<string, string> $context
*
* @return \Generator
*/
private static function context2replacements($context): \Generator
{
Expand Down

0 comments on commit a31679a

Please sign in to comment.