Correct Template Check

Turns out it wasn't correctly checking to see if it was a secure
template