diff --git a/Helpers.gs b/Helpers.gs index 6be809c..d8817b3 100644 --- a/Helpers.gs +++ b/Helpers.gs @@ -717,7 +717,12 @@ function createEvent(event, calendarTz){ } if (event.hasProperty('color')){ - newEvent.colorId = event.getFirstPropertyValue('color').toString(); + let colorID = event.getFirstPropertyValue('color').toString(); + if (Object.keys(CalendarApp.EventColor).includes(colorID)){ + newEvent.colorId = CalendarApp.EventColor[colorID]; + }else if(Object.values(CalendarApp.EventColor).includes(colorID)){ + newEvent.colorId = colorID; + }; //else unsupported value } return newEvent;