Revert "cut option maria_role as it as nothing to do with roles"

This reverts commit de1cbaea062c9169dcf1b8b2e4d844446b421b89.
Mariadb write the 'host' of a role as '' while mysql write '%'.
This commit is contained in:
Laurent Indermuehle 2023-10-11 16:38:24 +02:00
parent 7f6d5f5622
commit 2e2780b8f1
No known key found for this signature in database
GPG key ID: 93FA944C9F34DD09
3 changed files with 42 additions and 26 deletions

View file

@ -776,7 +776,8 @@ class Role():
if privs:
for db_table, priv in iteritems(privs):
privileges_grant(self.cursor, self.name, self.host,
db_table, priv, tls_requires=None)
db_table, priv, tls_requires=None,
maria_role=self.is_mariadb)
return True
@ -918,7 +919,7 @@ class Role():
result = user_mod(self.cursor, self.name, self.host,
None, None, None, None, None, None,
privs, append_privs, subtract_privs, None,
self.module, role=True)
self.module, role=True, maria_role=self.is_mariadb)
changed = result['changed']
if admin: