fixed an issue with the privileges grating and revoke