Skip to content
Snippets Groups Projects
Commit e4362e4e authored by Rafael Guterres Jeffman's avatar Rafael Guterres Jeffman
Browse files

sudocmdgroup: Change ipalib.errors to module utils ipalib_errors.

Instead o importing ipalib.errors, modules must use
ansible_freeipa_module.ipalib_errors.
parent d319b913
Branches
Tags
No related merge requests found
...@@ -107,9 +107,7 @@ from ansible.module_utils.basic import AnsibleModule ...@@ -107,9 +107,7 @@ from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils._text import to_text from ansible.module_utils._text import to_text
from ansible.module_utils.ansible_freeipa_module import temp_kinit, \ from ansible.module_utils.ansible_freeipa_module import temp_kinit, \
temp_kdestroy, valid_creds, api_connect, api_command, compare_args_ipa, \ temp_kdestroy, valid_creds, api_connect, api_command, compare_args_ipa, \
gen_add_del_lists gen_add_del_lists, ipalib_errors
import ipalib
def find_sudocmdgroup(module, name): def find_sudocmdgroup(module, name):
...@@ -117,7 +115,7 @@ def find_sudocmdgroup(module, name): ...@@ -117,7 +115,7 @@ def find_sudocmdgroup(module, name):
try: try:
_result = api_command(module, "sudocmdgroup_show", to_text(name), args) _result = api_command(module, "sudocmdgroup_show", to_text(name), args)
except ipalib.errors.NotFound: except ipalib_errors.NotFound:
return None return None
else: else:
return _result["result"] return _result["result"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment