From 031e2af3111432d5c7184f6934c66deeb8d70895 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Thu, 11 May 2017 20:59:51 -0700 Subject: [PATCH] Only show update/reboot for host card if available https://www.pivotaltracker.com/story/show/145135469 --- panels/hassio/dashboard/hassio-host-info.html | 30 +++++++++++++------ 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/panels/hassio/dashboard/hassio-host-info.html b/panels/hassio/dashboard/hassio-host-info.html index acfd70cced..6770c594b2 100644 --- a/panels/hassio/dashboard/hassio-host-info.html +++ b/panels/hassio/dashboard/hassio-host-info.html @@ -43,15 +43,19 @@
- Update - Reboot + +
@@ -71,5 +75,13 @@ Polymer({ value: {}, }, }, + + computeUpdateAvailable: function (data) { + return data.version !== data.last_version; + }, + + computeRebootAvailable: function (data) { + return data.features && data.features.indexOf("reboot") !== -1; + }, });