Skip to content

Commit 8046b18

Browse files
committed
fix: check to enable connect button after reset to default
1 parent 28c3b2e commit 8046b18

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/src/main/java/to/bitkit/ui/settings/advanced/ElectrumConfigViewModel.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,12 +113,12 @@ class ElectrumConfigViewModel @Inject constructor(
113113
fun resetToDefault() {
114114
val defaultServer = ElectrumServer.parse(Env.defaultElectrumServer)
115115
_uiState.update {
116-
it.copy(
116+
val newState = it.copy(
117117
host = defaultServer.host,
118118
port = defaultServer.getPort().toString(),
119119
protocol = defaultServer.protocol,
120-
hasEdited = false,
121120
)
121+
newState.copy(hasEdited = computeHasEdited(newState))
122122
}
123123
}
124124

0 commit comments

Comments
 (0)