mirror of
https://github.com/lnbits/lnbits.git
synced 2025-12-11 13:12:28 +01:00
feat: reduce initial requests on wallet page (#2335)
* feat: reduce initial request on wallet page - refactor allowed_currencies into function to use in generic and api. - remove currencies request in frontend move it to generic - dont request balance on first payments fetch
This commit is contained in:
@@ -176,6 +176,16 @@ currencies = {
|
||||
}
|
||||
|
||||
|
||||
def allowed_currencies():
|
||||
if len(settings.lnbits_allowed_currencies) > 0:
|
||||
return [
|
||||
item
|
||||
for item in currencies.keys()
|
||||
if item.upper() in settings.lnbits_allowed_currencies
|
||||
]
|
||||
return list(currencies.keys())
|
||||
|
||||
|
||||
class Provider(NamedTuple):
|
||||
name: str
|
||||
domain: str
|
||||
|
||||
Reference in New Issue
Block a user