Skip to content

Commit

Permalink
Allow spaces in user name. Refs #1798
Browse files Browse the repository at this point in the history
  • Loading branch information
yury authored and Carlos Cabanero committed Aug 22, 2023
1 parent f76c001 commit 53ee7e4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions Settings/ViewControllers/BKHosts/HostView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -548,12 +548,7 @@ struct HostView: View {
throw FormValidationError.general(
message: "HostName is required."
)
}

let cleanUser = _user.trimmingCharacters(in: .whitespacesAndNewlines)
if let _ = cleanUser.rangeOfCharacter(from: .whitespacesAndNewlines) {
throw FormValidationError.general(message: "Spaces are not permitted in the user name.")
}
}
}

private func _saveHost() {
Expand Down

0 comments on commit 53ee7e4

Please sign in to comment.