fixed missing currency code get config issue ( #8669mnvqf )
This commit is contained in:
parent
36ffeb3b4c
commit
463fc3cb89
@ -232,13 +232,13 @@ class Currencies extends Controller
|
||||
|
||||
$code = request('code');
|
||||
|
||||
if ($code) {
|
||||
$currencies = Currency::all()->pluck('rate', 'code');
|
||||
|
||||
if ($code) {
|
||||
$currency = config('money.' . $code);
|
||||
|
||||
$currency['rate'] = isset($currencies[$code]) ? $currencies[$code] : null;
|
||||
$currency['symbol_first'] = $currency['symbol_first'] ? 1 : 0;
|
||||
$currency['symbol_first'] = ! empty($currency['symbol_first']) ? 1 : 0;
|
||||
|
||||
$json = (object) $currency;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user