From 56749e29c4ca0802e23487676fe24e9f24e2aaf5 Mon Sep 17 00:00:00 2001 From: Thomas Forgione Date: Sun, 4 Oct 2020 18:53:54 +0200 Subject: [PATCH] Fix bug decode, make date optional --- src/Twitch.elm | 2 +- src/Views.elm | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Twitch.elm b/src/Twitch.elm index 17d4fcc..54423d9 100644 --- a/src/Twitch.elm +++ b/src/Twitch.elm @@ -247,4 +247,4 @@ decodeVideo url = Decode.map3 (\x y -> Video x url y) (Decode.field "title" Decode.string) (Decode.map Basics.round (Decode.field "duration" Decode.float)) - (Decode.nullable (Decode.field "date" Iso8601.decoder)) + (Decode.maybe (Decode.field "date" Iso8601.decoder)) diff --git a/src/Views.elm b/src/Views.elm index bdc450e..01d4c1c 100644 --- a/src/Views.elm +++ b/src/Views.elm @@ -284,6 +284,7 @@ videoView zone playlist video = [ Element.column [ Element.width (Element.fillPortion 2) , Element.spacing 10 + , Element.alignTop ] [ Keyed.el [ Element.width Element.fill