What changed, and why it matters
This commit fixes a UI mix-up in the Cake Wallet transaction filter. Previously, the 'Send' filter button was wired to incoming transactions and the 'Receive' button was wired to outgoing transactions, so tapping them would show the wrong list. The patch swaps the labels back to their correct transaction directions. It also fixes a related exchange/trade filter bug where the filter's on/off state was misreported, and makes sure toggling 'all' also updates the exchange filter items. There is no security vulnerability here—just a user-interface bug that could confuse users about which transactions are displayed.
No security action required. Treat as a normal bug-fix release. If regression testing is performed, verify that Send shows outgoing transactions, Receive shows incoming transactions, and the 'All' toggle correctly updates both transaction and exchange filters.
Security signals we found
No security-relevant code paths modified
No input validation, cryptography, authentication, or authorization changes
No memory safety, injection, or secret-handling changes
Change is purely UI/UX filter wiring
Evidence from the diff
In lib/view_model/dashboard/dashboard_view_model.dart, two FilterItem definitions had their value/onChanged callbacks swapped: the ‘Send’ caption was bound to displayIncoming/toggleIncoming and ‘Receive’ to displayOutgoing/toggleOutgoing. The patch corrects these to displayOutgoing/toggleOutgoing for Send and displayIncoming/toggleIncoming for Receive. Additionally, the SwapFilterItem value callback is changed from displayAllTrades to enabledProviders>0, and a new loop over exchangeFilterItems is added in the all-transactions toggle logic so exchange filters are also synchronized. These are functional/UI correctness changes, not security fixes.
Changed components
lib/view_model/dashboard/dashboard_view_model.dartDashboard transaction filter UISend/Receive filter buttonsExchange/Swap filter toggleInspect captured patch +10 / −5
diff --git a/lib/view_model/dashboard/dashboard_view_model.dart b/lib/view_model/dashboard/dashboard_view_model.dart
index 02c373f0..bb34a134 100644
--- a/lib/view_model/dashboard/dashboard_view_model.dart
+++ b/lib/view_model/dashboard/dashboard_view_model.dart
@@ -102,13 +102,13 @@ abstract class DashboardViewModelBase with Store {
// caption: S.current.all_transactions,
// onChanged: transactionFilterStore.toggleAll),
FilterItem(
- value: () => transactionFilterStore.displayIncoming,
+ value: () => transactionFilterStore.displayOutgoing,
caption: S.current.send,
- onChanged: transactionFilterStore.toggleIncoming),
+ onChanged: transactionFilterStore.toggleOutgoing),
FilterItem(
- value: () => transactionFilterStore.displayOutgoing,
+ value: () => transactionFilterStore.displayIncoming,
caption: S.current.receive,
- onChanged: transactionFilterStore.toggleOutgoing),
+ onChanged: transactionFilterStore.toggleIncoming),
if (appStore.wallet!.type == WalletType.bitcoin)
FilterItem(
value: () => transactionFilterStore.displaySilentPayments,
@@ -118,7 +118,7 @@ abstract class DashboardViewModelBase with Store {
SwapFilterItem(
enabledProviders: () => tradeFilterStore.enabledProviders,
allEnabled: () => tradeFilterStore.displayAllTrades,
- value: () => tradeFilterStore.displayAllTrades,
+ value: () => tradeFilterStore.enabledProviders>0,
onChanged: () =>
tradeFilterStore.toggleDisplayExchange(ExchangeProviderDescription.all)),
FilterItem(
@@ -406,6 +406,11 @@ abstract class DashboardViewModelBase with Store {
item.onChanged();
}
}
+ for (final item in exchangeFilterItems) {
+ if (item.value() != value) {
+ item.onChanged();
+ }
+ }
}
@action
Why this scored 19/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.