diff options
author | Christian Adams <chadams@redhat.com> | 2023-07-27 00:38:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-27 00:38:05 +0200 |
commit | b549ae1efacac2cc7ea9e09dbdac375048b5a20b (patch) | |
tree | a1bf653d49960eb8c93002dc78c32ce3bf853fce /awx_collection/plugins | |
parent | fixes docs link for controller versions >= 4.3 (#14287) (diff) | |
download | awx-b549ae1efacac2cc7ea9e09dbdac375048b5a20b.tar.xz awx-b549ae1efacac2cc7ea9e09dbdac375048b5a20b.zip |
Only show the product version header when the requester is authenticated (#14135)
Diffstat (limited to 'awx_collection/plugins')
-rw-r--r-- | awx_collection/plugins/module_utils/controller_api.py | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/awx_collection/plugins/module_utils/controller_api.py b/awx_collection/plugins/module_utils/controller_api.py index 1b7eccee1f..5f59548ba9 100644 --- a/awx_collection/plugins/module_utils/controller_api.py +++ b/awx_collection/plugins/module_utils/controller_api.py @@ -533,13 +533,7 @@ class ControllerAPIModule(ControllerModule): controller_version = response.info().getheader('X-API-Product-Version', None) parsed_collection_version = Version(self._COLLECTION_VERSION).version - if not controller_version: - self.warn( - "You are using the {0} version of this collection but connecting to a controller that did not return a version".format( - self._COLLECTION_VERSION - ) - ) - else: + if controller_version: parsed_controller_version = Version(controller_version).version if controller_type == 'AWX': collection_compare_ver = parsed_collection_version[0] |