Add Core portnums, reduce MQTT password size

This commit is contained in:
Garth Vander Houwen 2025-02-25 07:02:10 -08:00
parent 6e6de4da64
commit b9e99fbe0e
3 changed files with 9 additions and 2 deletions

View file

@ -196,7 +196,6 @@ struct MQTTConfig: View {
}
.keyboardType(.default)
.scrollDismissesKeyboard(.interactively)
HStack {
Label("password", systemImage: "wallet.pass")
TextField("password", text: $password)
@ -206,7 +205,7 @@ struct MQTTConfig: View {
.onChange(of: password) {
var totalBytes = password.utf8.count
// Only mess with the value if it is too big
while totalBytes > 62 {
while totalBytes > 30 {
password = String(password.dropLast())
totalBytes = password.utf8.count
}