Fixed template path issues