mirror of
https://github.com/ansible-collections/community.mysql.git
synced 2025-08-25 07:21:45 -07:00
Fix: Only revoke grant option if it exists and absence is requested
This commit is contained in:
parent
b8ff861135
commit
4c8a985997
1 changed files with 1 additions and 2 deletions
|
@ -367,8 +367,7 @@ def user_mod(cursor, user, host, host_all, password, encrypted,
|
|||
#
|
||||
# For more details
|
||||
# https://github.com/ansible-collections/community.mysql/issues/77#issuecomment-1209693807
|
||||
if 'GRANT' in grant_privs:
|
||||
grant_option = 'GRANT' in revoke_privs and 'GRANT' not in grant_privs
|
||||
grant_option = 'GRANT' in revoke_privs and 'GRANT' not in grant_privs
|
||||
|
||||
if grant_privs == ['GRANT']:
|
||||
# USAGE grants no privileges, it is only needed because 'WITH GRANT OPTION' cannot stand alone
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue