template upgrade