diff options
author | max99x <max99x@gmail.com> | 2011-06-25 11:03:21 +0300 |
---|---|---|
committer | max99x <max99x@gmail.com> | 2011-06-25 11:03:21 +0300 |
commit | 86a02b61c67301015318a159c0beb619ff8a1178 (patch) | |
tree | aaade2a9ae672a7ccf16081d59d924d5aa53bae7 | |
parent | 4217219cd94bb814a485f18f7d041e874f3e86f5 (diff) |
Fixed stdin() returning undefined in browser cotext if the user
clicks "Cancel" in the prompt dialog.
-rw-r--r-- | src/library.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/library.js b/src/library.js index d2b05764..8ec82c22 100644 --- a/src/library.js +++ b/src/library.js @@ -277,7 +277,7 @@ var Library = { } } else { Module.stdin = function stdin(prompt) { - return window.prompt(prompt); + return window.prompt(prompt) || ''; }; } |