Skip to content

Commit

Permalink
Return the events, even they are empty.
Browse files Browse the repository at this point in the history
  • Loading branch information
Burgy Benjamin committed Feb 13, 2024
1 parent 977e65a commit c2229b2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: '3'
services:
ksuite-middleware:
build: .
image: minidfx/ksuite-middleware:v0.6.0
image: minidfx/ksuite-middleware:v0.6.1
environment:
- SECRET_KEY_BASE=<secret>
- PHX_HOST=<host>
Expand Down
4 changes: 1 addition & 3 deletions lib/ksuite_middleware_web/controllers/calendar_json.ex
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
defmodule KsuiteMiddlewareWeb.CalendarJSON do
alias KsuiteMiddlewareWeb.Models.KsuiteCalendarEvent

def events(%{events: [%KsuiteCalendarEvent{} | _] = events}), do: events
def events(%{events: events}), do: events

def render("400.json", %{reason: reason}),
do: %{title: "invalid argument", status: 400, detail: reason}
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ defmodule KsuiteMiddleware.MixProject do
def project do
[
app: :ksuite_middleware,
version: "0.6.0",
version: "0.6.1",
elixir: "~> 1.14",
elixirc_paths: elixirc_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
Expand Down

0 comments on commit c2229b2

Please sign in to comment.