Dev polina

why have this huge if staement? why not have templatename be the actual template so you can just say:

return templates[ templateName ]( data );