remove requirement for galaxy credentials to belong to an organization (#16075) (#7066)

This commit is contained in:
Peter Braun 2025-08-15 22:27:22 +02:00 committed by GitHub
parent e82de50edb
commit e8c4b302ad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3271,11 +3271,6 @@ class CredentialSerializer(BaseSerializer):
ret.remove(field)
return ret
def validate_organization(self, org):
if self.instance and (not self.instance.managed) and self.instance.credential_type.kind == 'galaxy' and org is None:
raise serializers.ValidationError(_("Galaxy credentials must be owned by an Organization."))
return org
def validate_credential_type(self, credential_type):
if self.instance and credential_type.pk != self.instance.credential_type.pk:
for related_objects in (