Skip to content

Commit

Permalink
It is recommended not to use reserved keyword "default".
Browse files Browse the repository at this point in the history
  • Loading branch information
remcotolsma committed Oct 11, 2023
1 parent 73632a1 commit e2543fa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Methods.php
Original file line number Diff line number Diff line change
Expand Up @@ -188,10 +188,10 @@ class Methods {
* Transform WordPress payment method to MultiSafepay method.
*
* @param string|null $payment_method Payment method.
* @param string|null $default Default payment method.
* @param string|null $fallback Default payment method.
* @return string|null
*/
public static function transform( $payment_method, $default = null ) {
public static function transform( $payment_method, $fallback = null ) {
if ( ! \is_scalar( $payment_method ) ) {
return null;
}
Expand All @@ -200,7 +200,7 @@ public static function transform( $payment_method, $default = null ) {
return self::$map[ $payment_method ];
}

return $default;
return $fallback;
}

/**
Expand Down

0 comments on commit e2543fa

Please sign in to comment.