Update template to use strings, fn instead of regex with CORS