Skip to content

Commit

Permalink
Fixed outdate
Browse files Browse the repository at this point in the history
  • Loading branch information
donob4n committed Apr 1, 2020
1 parent 36e4b31 commit a060387
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions qubesmanager/qube_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,18 +223,18 @@ def update(self, update_size_on_disk=False, event=None):
if hasattr(self.vm, 'template') and \
self.vm.template.is_running():
self.state.outdated = "to-be-outdated"

if not self.state.outdated:
else:
for vol in self.vm.volumes.values():
if vol.is_outdated():
self.state.outdated = "outdated"
break
else:
self.state.outdated = ""

if self.vm.klass in {'TemplateVM', 'StandaloneVM'} and \
self.vm.features.get('updates-available', False):
self.state.outdated = 'update'


if not event or event.endswith(':label'):
self.label = self.vm.label
if not event or event.endswith(':template'):
Expand Down Expand Up @@ -806,7 +806,7 @@ def on_domain_status_changed(self, vm, event, **_kwargs):
self.qubes_model.info_by_id[vm.qid].update(event=event)
if vm.klass in {'TemplateVM'}:
for appvm in vm.appvms:
self.qubes_model.info_by_id[appvm.qid].update("outdated")
self.qubes_model.info_by_id[appvm.qid].update(event="outdated")
self.proxy.invalidate()
self.table_selection_changed()
except exc.QubesPropertyAccessError:
Expand Down

0 comments on commit a060387

Please sign in to comment.