Skip to content

Commit

Permalink
Fix bug in options handling
Browse files Browse the repository at this point in the history
  • Loading branch information
longouyang committed Jan 12, 2017
1 parent 47af37e commit 1cfd96d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions docs/webppl-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -42616,8 +42616,8 @@ var CodeEditor = React.createClass({
}
}
},
makeResultContainer: function (options) {
// TODO: take property arguments so that we can, e.g., make the div inline or have a border or something
makeResultContainer: function (_options) {
var options = _.defaults(_options || {}, {});
this.addResult(_.extend({ type: 'DOM' }));

// return the most recent custom component
Expand Down
4 changes: 3 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,9 @@ var CodeEditor = React.createClass({
}
}
},
makeResultContainer: function(options) {
makeResultContainer: function(_options) {
var options = _.defaults(_options || {},
{});
this.addResult(_.extend({type: 'DOM'}));

// return the most recent custom component
Expand Down

0 comments on commit 1cfd96d

Please sign in to comment.