template helpers modified