diff options
| author | Mitch Jackson <mitch@freeside.biz> | 2019-01-30 01:27:44 -0500 |
|---|---|---|
| committer | Mitch Jackson <mitch@freeside.biz> | 2019-01-30 01:28:53 -0500 |
| commit | 44cff6ff89f50eb856dee0adb8fab6b1abd5310b (patch) | |
| tree | d4886c2f0d9ecb919c77e3603840a66feab7a2d9 | |
| parent | a415347b25229ac13fa84ed8b8e5f2f5ee14205f (diff) | |
RT# 82010 Fix bug where selfservice payment form may not appear
| -rw-r--r-- | FS/FS/ClientAPI/MyAccount.pm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/FS/FS/ClientAPI/MyAccount.pm b/FS/FS/ClientAPI/MyAccount.pm index a3198611d..7d49c87e1 100644 --- a/FS/FS/ClientAPI/MyAccount.pm +++ b/FS/FS/ClientAPI/MyAccount.pm @@ -930,6 +930,12 @@ sub payment_info { $return{credit_card_surcharge_percentage} = $conf->config('credit-card-surcharge-percentage', $cust_main->agentnum); $return{credit_card_surcharge_flatfee} = $conf->config('credit-card-surcharge-flatfee', $cust_main->agentnum); + # A value for 'payby' must be defined in %return + $return{payby} = $return{paybys}->[0] + if !$return{payby} + && ref $return{paybys} + && scalar @{ $return{paybys} }; + return { 'error' => '', %return, }; |
