mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2024-12-24 06:52:40 -05:00
fix value
This commit is contained in:
parent
4b1307bb11
commit
01db5da8ce
2 changed files with 2 additions and 2 deletions
|
@ -298,7 +298,7 @@ class Blocks {
|
|||
if (!block.fields[args.name]) return;
|
||||
if (args.name === 'VARIABLE') {
|
||||
// Get variable name using the id in args.value.
|
||||
const variable = optRuntime.getEditingTarget().lookupVariableById(args.id);
|
||||
const variable = optRuntime.getEditingTarget().lookupVariableById(args.value);
|
||||
if (variable) {
|
||||
block.fields[args.name].value = variable.name;
|
||||
block.fields[args.name].id = args.value;
|
||||
|
|
|
@ -169,7 +169,7 @@ class Target extends EventEmitter {
|
|||
id: id,
|
||||
element: 'field',
|
||||
name: 'VARIABLE',
|
||||
value: newName
|
||||
value: id
|
||||
}, this.runtime);
|
||||
this.runtime.requestUpdateMonitor(Map({
|
||||
id: id,
|
||||
|
|
Loading…
Reference in a new issue