show enabled only if configured to receive or send (handle client settings wipe)

This commit is contained in:
Riccardo Balbo 2024-10-15 23:07:25 +02:00 committed by k00b
parent 2ef7651421
commit 40f24236fd
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ function useWalletInner (name) {
const [config, saveConfig, clearConfig] = useConfig(walletDef)
const available = (!walletDef?.isAvailable || walletDef?.isAvailable())
const status = config?.enabled && available ? Status.Enabled : Status.Initialized
const status = config?.enabled && available && (config.canSend || config.canReceive) ? Status.Enabled : Status.Initialized
const enabled = status === Status.Enabled
const priority = config?.priority
const hasConfig = walletDef?.fields?.length > 0