From 0cba27cba2b44756389d50bc113f23a2be87e978 Mon Sep 17 00:00:00 2001 From: Joris Date: Sun, 3 Jan 2016 00:19:55 +0100 Subject: Prevent to send multiple payments if the server is not answering --- src/client/elm/ServerCommunication.elm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/client/elm/ServerCommunication.elm') diff --git a/src/client/elm/ServerCommunication.elm b/src/client/elm/ServerCommunication.elm index 53612d8..7c46d79 100644 --- a/src/client/elm/ServerCommunication.elm +++ b/src/client/elm/ServerCommunication.elm @@ -35,7 +35,7 @@ sendRequest communication = AddPayment name cost frequency -> post (addPaymentURL name cost frequency) |> flip Task.andThen (decodeHttpValue <| "id" := paymentIdDecoder) - |> Task.map (\paymentId -> (U.UpdateLoggedIn (UL.AddPayment paymentId name cost frequency))) + |> Task.map (\paymentId -> (U.UpdateLoggedIn (UL.ValidateAddPayment paymentId name cost frequency))) DeletePayment payment frequency -> post (deletePaymentURL payment.id) -- cgit v1.2.3