A......... [ZBX-8448] validatePermissions() is now split into separate methods to validate write permissions to hosts, templates and host groups for hostgroup.massadd, hostgroup.massupdate and hostgroup.massremove methods. This also fixed incorrect object and group relation behaviour in hostgroup.massremove and hostgroup.massupdate methods.