Skip to content

Commit

Permalink
feat: remove password and authorization user as required field
Browse files Browse the repository at this point in the history
  • Loading branch information
psanders committed Mar 8, 2024
1 parent ef2cbd1 commit 635b59e
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 16 deletions.
8 changes: 3 additions & 5 deletions simplephone/dist/phone.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion simplephone/dist/phone.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions simplephone/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

<body>
<h1>SimplePhone</h1>

<table>
<tr>
<td>Display Name:</td>
Expand Down
10 changes: 4 additions & 6 deletions simplephone/public/lib/phone.js

Large diffs are not rendered by default.

6 changes: 2 additions & 4 deletions simplephone/src/phone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ class Phone {
}
},
userAgentOptions: {
displayName: this.displayNameInput.value,
displayName: this.displayNameInput.value || "Anonymous",
authorizationUsername: this.authorizationUserInput.value || this.usernameInput.value,
authorizationPassword: this.passwordInput.value,
allowLegacyNotifications: false,
Expand Down Expand Up @@ -167,9 +167,7 @@ class Phone {

hasAllRequiredFields() {
return (
this.displayNameInput.value &&
this.usernameInput.value &&
this.passwordInput.value &&
this.domainInput.value &&
this.serverInput.value &&
this.targetAORInput.value
Expand All @@ -194,7 +192,7 @@ class Phone {

saveConfig() {
if (!this.hasAllRequiredFields()) {
window.alert("All fields are required.");
window.alert("The following fields are required: Username, Domain, Signal Server, and Target AOR");
return;
}

Expand Down

0 comments on commit 635b59e

Please sign in to comment.