Skip to content
Snippets Groups Projects
Commit eafe0921 authored by Paul Kaplan's avatar Paul Kaplan
Browse files

Use vm#createVariable

parent 488ba96a
No related branches found
No related tags found
No related merge requests found
...@@ -127,7 +127,6 @@ class Blocks extends React.Component { ...@@ -127,7 +127,6 @@ class Blocks extends React.Component {
if (this.props.vm.editingTarget && !this.state.workspaceMetrics[this.props.vm.editingTarget.id]) { if (this.props.vm.editingTarget && !this.state.workspaceMetrics[this.props.vm.editingTarget.id]) {
this.onWorkspaceMetricsChange(); this.onWorkspaceMetricsChange();
} }
this.ScratchBlocks.Events.disable(); this.ScratchBlocks.Events.disable();
this.workspace.clear(); this.workspace.clear();
...@@ -152,6 +151,7 @@ class Blocks extends React.Component { ...@@ -152,6 +151,7 @@ class Blocks extends React.Component {
} }
handlePromptCallback (data) { handlePromptCallback (data) {
this.state.prompt.callback(data); this.state.prompt.callback(data);
this.props.vm.createVariable(data);
this.handlePromptClose(); this.handlePromptClose();
} }
handlePromptClose () { handlePromptClose () {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment