From c14bdfa147e014405ab410c5a76bebddbd9d228e Mon Sep 17 00:00:00 2001 From: ronreg-ribdev <56719257+ronreg-ribdev@users.noreply.github.com> Date: Mon, 1 Jun 2020 01:21:31 -0700 Subject: [PATCH] Get elevator json to frontend --- urbit/app/bartinfo.hoon | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/urbit/app/bartinfo.hoon b/urbit/app/bartinfo.hoon index bc4fe03..3cb69b5 100644 --- a/urbit/app/bartinfo.hoon +++ b/urbit/app/bartinfo.hoon @@ -183,8 +183,15 @@ |= response=client-response:iris ^- json =, format - ~& response - (pairs:enjs [[%yolo %b %.y] ~]) + =/ handler |= jon=json + ?> ?=(%o -.jon) + =/ root=json (~(got by p.jon) 'root') + ?> ?=(%o -.root) + =/ bsa=json (~(got by p.root) 'bsa') + ?> ?=(%a -.bsa) + ~& -.bsa + (pairs:enjs [[%elevators %a p.bsa] ~]) + (with-json-handler response handler) :: ++ poke-handle-http-request |= =inbound-request:eyre