mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2025-06-06 02:24:47 -04:00
add comment before using util.initParams
Co-Authored-By: mzgoddard <mzgoddard@gmail.com>
This commit is contained in:
parent
20ff75b776
commit
fefb032f17
1 changed files with 3 additions and 0 deletions
|
@ -38,6 +38,9 @@ class Scratch3ProcedureBlocks {
|
||||||
|
|
||||||
const [paramNames, paramIds, paramDefaults] = paramNamesIdsAndDefaults;
|
const [paramNames, paramIds, paramDefaults] = paramNamesIdsAndDefaults;
|
||||||
|
|
||||||
|
// Initialize params for the current stackFrame to {}, even if the procedure does
|
||||||
|
// not take any arguments. This is so that `getParam` down the line does not look
|
||||||
|
// at earlier stack frames for the values of a given parameter (#1729)
|
||||||
util.initParams();
|
util.initParams();
|
||||||
for (let i = 0; i < paramIds.length; i++) {
|
for (let i = 0; i < paramIds.length; i++) {
|
||||||
if (args.hasOwnProperty(paramIds[i])) {
|
if (args.hasOwnProperty(paramIds[i])) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue