Skip to content

Commit

Permalink
fix: Remove possibility to add watch accounts on release
Browse files Browse the repository at this point in the history
  • Loading branch information
alexjba committed Aug 5, 2024
1 parent 4a6b622 commit 566a954
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
20 changes: 13 additions & 7 deletions ui/app/AppLayouts/Wallet/views/AccountContextMenu.qml
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,19 @@ StatusMenu {
}
}

StatusAction {
objectName: "AccountMenu-AddWatchOnlyAccountAction-%1".arg(root.uniqueIdentifier)
text: qsTr("Add watched address")
enabled: !root.account
icon.name: "show"
onTriggered: {
root.addWatchOnlyAccountClicked()
Loader {
active: !production
sourceComponent: StatusAction {
objectName: "AccountMenu-AddWatchOnlyAccountAction-%1".arg(root.uniqueIdentifier)
text: qsTr("Add watched address")
enabled: !root.account
icon.name: "show"
onTriggered: {
root.addWatchOnlyAccountClicked()
}
}
onLoaded: {
root.addAction(item)
}
}
}
1 change: 1 addition & 0 deletions ui/imports/shared/popups/addaccount/states/Main.qml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ Item {
readonly property string addWatchOnlyAccKeyUid: Constants.appTranslatableConstants.addAccountLabelOptionAddWatchOnlyAcc
filters: [
FastExpressionFilter {
enabled: production
expression: model.keyPair.keyUid !== originModelWithoutWatchOnlyAcc.addWatchOnlyAccKeyUid
expectedRoles: ["keyPair"]
}
Expand Down

0 comments on commit 566a954

Please sign in to comment.