From d1ac198a7b64ce0a1aa7a3a9c45b268ce82d8d76 Mon Sep 17 00:00:00 2001 From: Mikael Fangel <34864484+MikaelFangel@users.noreply.github.com> Date: Fri, 26 Apr 2024 15:37:04 +0200 Subject: [PATCH] incident_api: added missing Jason encoders --- lib/incident_api.ex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/incident_api.ex b/lib/incident_api.ex index 1aa8b85..71d98f0 100644 --- a/lib/incident_api.ex +++ b/lib/incident_api.ex @@ -12,10 +12,12 @@ defmodule LogpointApi.IncidentApi do end defmodule IncidentComment do + @derive {Jason.Encoder, only: [:_id, :comments]} defstruct _id: "", comments: [] end defmodule IncidentCommentData do + @derive {Jason.Encoder, only: [:version, :states]} defstruct version: "0.1", states: [%IncidentComment{}] end