File tree Expand file tree Collapse file tree 1 file changed +1
-6
lines changed
lib/nerves_hub/extensions Expand file tree Collapse file tree 1 file changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -48,18 +48,13 @@ defmodule NervesHub.Extensions.Health do
4848
4949 @ impl NervesHub.Extensions
5050 def handle_in ( "report" , % { "value" => device_status } , socket ) do
51- device_meta =
52- for { key , val } <- Map . from_struct ( socket . assigns . device . firmware_metadata ) ,
53- into: % { } ,
54- do: { to_string ( key ) , to_string ( val ) }
55-
5651 # Separate metrics from health report to store in metrics table
5752 metrics = device_status [ "metrics" ] || % { }
5853
5954 health_report =
6055 device_status
6156 |> Map . delete ( "metrics" )
62- |> Map . put ( "metadata" , Map . merge ( device_status [ "metadata" ] , device_meta ) )
57+ |> Map . put ( "metadata" , device_status [ "metadata" ] )
6358
6459 device_health = % { "device_id" => socket . assigns . device . id , "data" => health_report }
6560
You can’t perform that action at this time.
0 commit comments