Skip to content

Commit 8117d8e

Browse files
committed
Bug fix in 'set style'
1 parent 6904582 commit 8117d8e

File tree

3 files changed

+14
-15
lines changed

3 files changed

+14
-15
lines changed

dist/easycoder-min.js

Lines changed: 10 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/easycoder.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5349,8 +5349,8 @@ const EasyCoder_Browser = {
53495349
target = document.getElementById(targetId);
53505350
}
53515351
const styleValue = program.getValue(command.styleValue);
5352-
if (!symbol.value[symbol.index]) {
5353-
program.runtimeError(command.lino, `Variable '${symbol.name}' has not been assigned.`);
5352+
if (!symbol.element[symbol.index]) {
5353+
program.runtimeError(command.lino, `Variable '${symbol.name}' has no DOM element.`);
53545354
return 0;
53555355
}
53565356
switch (command.type) {

js/easycoder/Browser.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2284,8 +2284,8 @@ const EasyCoder_Browser = {
22842284
target = document.getElementById(targetId);
22852285
}
22862286
const styleValue = program.getValue(command.styleValue);
2287-
if (!symbol.value[symbol.index]) {
2288-
program.runtimeError(command.lino, `Variable '${symbol.name}' has not been assigned.`);
2287+
if (!symbol.element[symbol.index]) {
2288+
program.runtimeError(command.lino, `Variable '${symbol.name}' has no DOM element.`);
22892289
return 0;
22902290
}
22912291
switch (command.type) {

0 commit comments

Comments
 (0)