Skip to content

Commit

Permalink
fixed baasbox#583 - Can't close new plugin prompt window on Safari
Browse files Browse the repository at this point in the history
  • Loading branch information
giastfader committed Feb 16, 2015
1 parent 28a6e8a commit c0f6c26
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion public/console/bbjs/baasboxgui.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ angular.module("console", ['ui.ace'])
function prompt(message,defaultValue){
var defer = $q.defer();
var response = $window.prompt(message,defaultValue);
if (response==null){
if (!response || /^\s*$/.test(response)){ //http://stackoverflow.com/a/3261380/3023373
defer.reject();
} else {
defer.resolve(response);
Expand Down

0 comments on commit c0f6c26

Please sign in to comment.