fix error with template names not being array