Skip to content

Commit

Permalink
Merge pull request #3 from conedevelopment/typos
Browse files Browse the repository at this point in the history
  • Loading branch information
iamgergo authored Dec 6, 2023
2 parents e3896dc + e002a78 commit 71330b3
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/StripeDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class StripeDriver extends Driver
public readonly StripeClient $client;

/**
* The payment redirect URL resovler callback.
* The payment redirect URL resolver callback.
*/
protected static ?Closure $redirectUrlAfterPayment = null;

Expand All @@ -47,13 +47,13 @@ public static function redirectUrlAfterPayment(Closure $callback): void
/**
* Resolve the redirect URL after payment.
*/
public function resolveRedirectUrlAfterPayment(Order $order, string $staus, Transaction $transaction = null): string
public function resolveRedirectUrlAfterPayment(Order $order, string $status, Transaction $transaction = null): string
{
if (! is_null(static::$redirectUrlAfterPayment)) {
return call_user_func_array(static::$redirectUrlAfterPayment, [$order, $staus, $transaction]);
return call_user_func_array(static::$redirectUrlAfterPayment, [$order, $status, $transaction]);
}

return match ($staus) {
return match ($status) {
'success' => $this->config['success_url'] ?? '/',
default => $this->config['cancel_url'] ?? '/',
};
Expand All @@ -62,17 +62,17 @@ public function resolveRedirectUrlAfterPayment(Order $order, string $staus, Tran
/**
* {@inheritdoc}
*/
public function pay(Order $order, float $amount = null, array $attrributes = []): Transaction
public function pay(Order $order, float $amount = null, array $attributes = []): Transaction
{
return $order->pay($amount, 'stripe', $attrributes);
return $order->pay($amount, 'stripe', $attributes);
}

/**
* {@inheritdoc}
*/
public function refund(Order $order, float $amount = null, array $attrributes = []): Transaction
public function refund(Order $order, float $amount = null, array $attributes = []): Transaction
{
return $order->refund($amount, 'stripe', $attrributes);
return $order->refund($amount, 'stripe', $attributes);
}

/**
Expand Down

0 comments on commit 71330b3

Please sign in to comment.