From 17391c1e000172418533a4eb42890d819570da14 Mon Sep 17 00:00:00 2001 From: signalhunter Date: Sat, 22 Aug 2020 03:11:29 -0400 Subject: [PATCH] Made the prototype functional --- sys/apps/system/trust.lua | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/sys/apps/system/trust.lua b/sys/apps/system/trust.lua index c795ab8..bb6a703 100644 --- a/sys/apps/system/trust.lua +++ b/sys/apps/system/trust.lua @@ -40,5 +40,14 @@ return UI.Tab { enable = function(self) self:reload() UI.Tab.enable(self) + end, + eventHandler = function(self, event) + if event.type == 'grid_select' then + local hosts = Util.readTable('usr/.known_hosts') + hosts[event.selected.id] = nil + Util.writeTable('usr/.known_hosts', hosts) + self:reload() + return true + end end } \ No newline at end of file