Skip to content

Commit

Permalink
Update to fix Psalm errors
Browse files Browse the repository at this point in the history
  • Loading branch information
htdat committed Oct 25, 2023
1 parent 1ea7ea1 commit 50f6f12
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/Internal/Payment/State/AbstractPaymentState.php
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,10 @@ public function complete_processing() {
* This method should only be called whenever the process is ready to transition
* to the next state, as each new state will be considered the payment's latest one.
*
* @template T
* @param class-string<T>|string $state_class The class of the state to crate.
* @template ConcreteState
* @param class-string<ConcreteState> | string $state_class The class of the state to crate.
*
* @return T
* @return AbstractPaymentState | ConcreteState
*
* @throws StateTransitionException In case the new state could not be created.
* @throws ContainerException When the dependency container cannot instantiate the state.
Expand Down
8 changes: 4 additions & 4 deletions src/Internal/Payment/State/StateFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ public function __construct( Container $container ) {
/**
* Creates a new state based on class name.
*
* @template T
* @param class-string<T>|string $state_class Name of the state class.
* @param PaymentContext $context Context for the new state.
* @template ConcreteState
* @param class-string<ConcreteState> | string $state_class Name of the state class.
* @param PaymentContext $context Context for the new state.
*
* @return T The generated payment state instance.
* @return AbstractPaymentState | ConcreteState The generated payment state instance.
* @throws ContainerException When the dependency container cannot instantiate the state.
* @throws StateTransitionException When the class name is not a state.
*/
Expand Down

0 comments on commit 50f6f12

Please sign in to comment.