Skip to content

Commit

Permalink
avoid function prefix for non-functions
Browse files Browse the repository at this point in the history
  • Loading branch information
scoates committed Oct 1, 2010
1 parent 38a4dd1 commit 4edeac8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions wsrc.js
Expand Up @@ -30,10 +30,11 @@ function saveContext(name, $_) {
});
var toolbox = {};
_.each(obj.toolbox, function(v, k) {
if (typeof v != 'function') {
if (typeof v === 'function') {
toolbox[k] = functionPrefix + v;
} else {
toolbox[k] = v;
}
toolbox[k] = functionPrefix + v;
});
obj.toolbox = toolbox;
delete obj['cookies'];
Expand Down

0 comments on commit 4edeac8

Please sign in to comment.