Variable assign_galaxy_credentials_to_org[1] has been set instead of set organization list fact without creds.
_current_cred_types and _current_credentials could be built from all objects that aren't managed by controller/tower, which are the ones shouldn't be removed or added as code because are controller/tower default objects. Here it might be a slightly difference when you handling tower or controller, but I didn't include the tower query, as this example is defined for aap. The difference query should be:
Variable
assign_galaxy_credentials_to_org
[1] has been set instead of set organization list fact without creds._current_cred_types
and_current_credentials
could be built from all objects that aren't managed by controller/tower, which are the ones shouldn't be removed or added as code because are controller/tower default objects. Here it might be a slightly difference when you handling tower or controller, but I didn't include the tower query, as this example is defined for aap. The difference query should be:query_params={'managed': false},
query_params={'managed_by_tower': false}
[1].-https://github.com/redhat-cop/controller_configuration/blob/devel/roles/organizations/tasks/main.yml#L10