diff --git a/Code.ts b/Code.ts index 2dcc90d..73f83d9 100644 --- a/Code.ts +++ b/Code.ts @@ -36,8 +36,8 @@ function copyBody( dest: GoogleAppsScript.Document.Body, index?: number ) { - var totalElements = source.getNumChildren(); - for (var j = 0; j < totalElements; ++j) { + const totalElements = source.getNumChildren(); + for (let j = 0; j < totalElements; ++j) { if (index) copyElement(source.getChild(j), dest, index + j); else copyElement(source.getChild(j), dest); }