Browse files

Closes #533 Only try to set 'newscript_' values if they were specified.

  • Loading branch information...
1 parent 774ccef commit d6c34c19566630a9555a9e7b6c6c66a7595eb96e @supahgreg supahgreg committed Sep 5, 2011
Showing with 4 additions and 2 deletions.
  1. +4 −2 extension/content/js/newscript.js
View
6 extension/content/js/newscript.js
@@ -109,8 +109,10 @@ function doInstall() {
Scriptish_openInEditor(script, window);
// persist values
- Scriptish_prefRoot.setValue("newscript_namespace", script.namespace);
- Scriptish_prefRoot.setValue("newscript_author", script.author);
+ if (script.namespace)
+ Scriptish_prefRoot.setValue("newscript_namespace", script.namespace);
+ if (script.author)
+ Scriptish_prefRoot.setValue("newscript_author", script.author);
return true;
}

0 comments on commit d6c34c1

Please sign in to comment.