aboutsummaryrefslogtreecommitdiff
path: root/src/client/ServerCommunication.elm
diff options
context:
space:
mode:
authorJoris2015-09-07 12:24:56 +0200
committerJoris2015-09-07 12:24:56 +0200
commitc1ec9b40fa84be2fd7067251461eda64d3bd8b74 (patch)
treefe10248371e1eb447684113452c14e3bbcb41f57 /src/client/ServerCommunication.elm
parent1d6a75b8321f324baa5f5421ce9f85637e8a706d (diff)
downloadbudget-c1ec9b40fa84be2fd7067251461eda64d3bd8b74.tar.gz
budget-c1ec9b40fa84be2fd7067251461eda64d3bd8b74.tar.bz2
budget-c1ec9b40fa84be2fd7067251461eda64d3bd8b74.zip
Fixing logout page
Diffstat (limited to 'src/client/ServerCommunication.elm')
-rw-r--r--src/client/ServerCommunication.elm6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/client/ServerCommunication.elm b/src/client/ServerCommunication.elm
index 6d65552..fefbbff 100644
--- a/src/client/ServerCommunication.elm
+++ b/src/client/ServerCommunication.elm
@@ -76,8 +76,8 @@ simple method url =
serverResult : Communication -> Http.Response -> Task Http.RawError U.Action
serverResult communication response =
- if response.status == 200
- then
+ case response.status of
+ 200 ->
case communication of
NoCommunication ->
Task.succeed U.NoOp
@@ -107,7 +107,7 @@ serverResult communication response =
response
SignOut ->
Task.succeed (U.GoSignInView)
- else
+ errorStatus ->
decodeResponse
messageDecoder
(\error ->