Fix property name: use CanUseHotWallet and CanCreateNewColdWallet
What changed, and why it matters
This is a tiny one-line fix in a BTCPay Server web page that checks whether a user is allowed to set up certain types of cryptocurrency wallets. The old code referenced two properties that appear to have been renamed or replaced. The change simply swaps in the current property names so the page renders the wallet-setup section correctly. It is most likely a routine bug fix, but because it touches permission checks for wallet creation, it could have security-adjacent effects if the wrong users were shown (or hidden from) wallet options.
Review the corresponding view model/controller to confirm the semantics of CanUseHotWallet and CanCreateNewColdWallet, and verify that the old properties were not still populated by a different code path. If this was a bug fix for an authorization issue, consider whether a security advisory is warranted and add regression tests for the wallet-setup permission checks.
Security signals we found
View-level authorization check for wallet creation capabilities
Property rename in permission model
Potential mismatch between view logic and backend policy
Evidence from the diff
In BTCPayServer/Views/UIStores/SetupWallet.cshtml, the Razor conditional guarding display of wallet setup options was updated from Model.CanCreateHotWallet || Model.CanCreateWalletWatchOnly to Model.CanUseHotWallet || Model.CanCreateNewColdWallet. This aligns the view with renamed/updated model properties. The diff alone does not reveal whether the old properties were undefined (which would silently hide the block) or still existed with stale semantics. If the old names were stale, the patch could correct a logic/authorization bug; if they were simply aliases, the change is cosmetic.
Changed components
BTCPayServer/Views/UIStores/SetupWallet.cshtmlInspect captured patch +1 / −1
diff --git a/BTCPayServer/Views/UIStores/SetupWallet.cshtml b/BTCPayServer/Views/UIStores/SetupWallet.cshtml
index 60cc805..156aeb6 100644
--- a/BTCPayServer/Views/UIStores/SetupWallet.cshtml
+++ b/BTCPayServer/Views/UIStores/SetupWallet.cshtml
@@ -24,7 +24,7 @@
</div>
</div>
-@if (Model.CanCreateHotWallet || Model.CanCreateWalletWatchOnly)
+@if (Model.CanUseHotWallet || Model.CanCreateNewColdWallet)
{
<br>
<div class="mt-5">
Why this scored 29/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.