From e158e31bf189f7094ce35a76665de187878957a7 Mon Sep 17 00:00:00 2001 From: Adam Goldsmith Date: Sat, 20 Jun 2020 18:09:07 -0400 Subject: [PATCH] Move output folder ID into a constant --- Code.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Code.ts b/Code.ts index bcd5eed..1cbdd18 100644 --- a/Code.ts +++ b/Code.ts @@ -1,3 +1,5 @@ +const OUTPUT_FOLDER_ID = '1ROyJXk-QANTHM6Jiw0ne3EQiR1f2UsLr'; + function onOpen() { const ui = SpreadsheetApp.getUi(); ui.createMenu('CMS Document Generation') @@ -81,9 +83,7 @@ function generateForRow( const template_doc = DocumentApp.openById(row['Template ID']); const source_file = DriveApp.getFileById(row['Document ID']); - const out_folder = DriveApp.getFolderById( - '1ROyJXk-QANTHM6Jiw0ne3EQiR1f2UsLr' - ); + const out_folder = DriveApp.getFolderById(OUTPUT_FOLDER_ID); const out_name = row['Document Name'] + '_' + row['Version'];