Remove setAllowHash for template 3.1 compatibility