Skip to content

Commit 056b525

Browse files
committed
fix: empty instance url is ok
1 parent 732883b commit 056b525

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

wrapper/src/main/java/io/yubicolabs/wwwwallet/MainViewModel.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ class MainViewModel : ViewModel() {
121121
when {
122122
value.startsWith("https://") -> value
123123
value.startsWith("http://") -> value.replace("http", "https")
124-
value.first().isLetter() -> "https://$value" // forgot the https?
124+
value.isNotEmpty() && value.first().isLetter() -> "https://$value" // forgot the https?
125125
else -> value // for direct ip addresses
126126
}
127127

0 commit comments

Comments
 (0)