trap case that this code is running without currentScript being set (came up in template experiments)