From 75804df1cb231033f94183e41cdf79d36d8f6710 Mon Sep 17 00:00:00 2001 From: Joris Date: Sun, 21 Aug 2016 14:30:40 +0200 Subject: Show a message if there is an error during a server request --- src/client/elm/Model/Income.elm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/client/elm/Model/Income.elm') diff --git a/src/client/elm/Model/Income.elm b/src/client/elm/Model/Income.elm index 06ba772..a5ca34b 100644 --- a/src/client/elm/Model/Income.elm +++ b/src/client/elm/Model/Income.elm @@ -81,8 +81,8 @@ getIncomeAt time incomes = then Just { userId = x.userId, time = time, amount = x.amount } else Nothing x1 :: x2 :: xs -> - if x1.time < time && x2.time > time - then Just { userId = x2.userId, time = time, amount = x2.amount } + if x1.time < time && x2.time >= time + then Just { userId = x1.userId, time = time, amount = x1.amount } else getIncomeAt time (x2 :: xs) [] -> Nothing -- cgit v1.2.3