lib/perus/server/models/system.rb in perus-0.1.9 vs lib/perus/server/models/system.rb in perus-0.1.10

- old
+ new

@@ -50,9 +50,17 @@ # config_hashes, actions referring to scripts return an array. # flatten is needed to merge the two response types together. pending_actions.collect(&:config_hashes).flatten end + def config_hash + { + id: id, + metrics: config.metric_hashes, + actions: pending_actions.map(&:config_hash).flatten + } + end + # --------------------------------------- # metrics # --------------------------------------- def save_metric_errors(params, timestamp)