Skip to content

Commit 92ba573

Browse files
committed
Fixed user settings change bug not allowing abort out of user selection process
1 parent 6e563b6 commit 92ba573

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

ddoc2.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -809,28 +809,33 @@ if (!debugOnly) {
809809
}
810810
break;
811811
case '$': //change debugging flags for this user
812+
var dropOut = false;
813+
var un;
814+
812815
if (user.security.level < 80) {
813816
userRecords.userDataUI.queryDebugSettings(user.number);
814817
} else {
815818
console.putmsg(yellow + high_intensity + "User name to " +
816819
"modify debug settings for: ");
817-
var un = bbs.finduser(console.getstr());
820+
un = bbs.finduser(console.getstr());
818821

819822
while (un < 1) {
820823
console.putmsg(red + high_intensity + "User not " +
821-
"found. Enter another username or <ENTER> to " +
824+
"found. Enter another username or \"DONE\" to " +
822825
" escape.\nUsername: ");
823826
un = console.getstr();
824827

825-
if (un == "") {
826-
break;
828+
if (un == "DONE") {
829+
dropOut = true;
827830
} else {
828831
un = bbs.finduser(un);
829832
}
830833
}
831834

832835
//we should have a valid # now or else be out of here :P
833-
userRecords.userDataUI.queryDebugSettings(un);
836+
if (!dropOut) {
837+
userRecords.userDataUI.queryDebugSettings(un);
838+
}
834839
}
835840
break;
836841
default:

0 commit comments

Comments
 (0)