fixed teplates error path