upgrade templates