Skip to content

Commit

Permalink
Fix serialization of repository field on Publications
Browse files Browse the repository at this point in the history
  • Loading branch information
dralley committed May 24, 2019
1 parent 92e1009 commit 60dac54
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pulpcore/app/serializers/publication.py
Expand Up @@ -28,12 +28,13 @@ class PublicationSerializer(MasterModelSerializer):
queryset=models.RepositoryVersion.objects.all(),
required=False,
)
repository = serializers.HyperlinkedRelatedField(
repository = RelatedField(
help_text=_('A URI of the repository to be published.'),
required=False,
label=_('Repository'),
queryset=models.Repository.objects.all(),
view_name='repositories-detail',
write_only=True
)

def validate(self, data):
Expand Down

0 comments on commit 60dac54

Please sign in to comment.