Skip to content

Commit

Permalink
Fixes build_status_label, not always returned (#624)
Browse files Browse the repository at this point in the history
  • Loading branch information
ldjebran authored and san7ket committed Mar 19, 2019
1 parent ff75d79 commit cc9266d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions nailgun/entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -4085,6 +4085,7 @@ def read(self, entity=None, attrs=None, ignore=None, params=None):
ignore.add('image')
# host id is required for interface initialization
ignore.add('interface')
ignore.add('build_status_label')
result = super(Host, self).read(entity, attrs, ignore, params)
if attrs.get('image_id'):
result.image = Image(
Expand All @@ -4103,6 +4104,8 @@ def read(self, entity=None, attrs=None, ignore=None, params=None):
)
for interface in attrs['interfaces']
]
if 'build_status_label' in attrs:
result.build_status_label = attrs['build_status_label']
return result

@signals.emit(sender=signals.SENDER_CLASS, post_result_name='entity')
Expand Down

0 comments on commit cc9266d

Please sign in to comment.