Skip to content

Commit

Permalink
Fix sanity checks
Browse files Browse the repository at this point in the history
  • Loading branch information
wfelipew committed Jan 16, 2024
1 parent 690ac6f commit aa7c5be
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions plugins/module_utils/mysql.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,12 +206,14 @@ def get_server_version(cursor):

return version_str


def get_server_implementation(cursor):
if 'mariadb' in get_server_version(cursor).lower():
return "mariadb"
else:
return "mysql"


def is_mariadb(implementation):
if implementation == "mariadb":
return True
Expand All @@ -224,6 +226,7 @@ def is_mysql(implementation):
else:
return False

Check warning on line 227 in plugins/module_utils/mysql.py

View check run for this annotation

Codecov / codecov/patch

plugins/module_utils/mysql.py#L227

Added line #L227 was not covered by tests


def set_session_vars(module, cursor, session_vars):
"""Set session vars."""
for var, value in session_vars.items():
Expand Down

0 comments on commit aa7c5be

Please sign in to comment.