Skip to content

Commit

Permalink
Merge pull request #10 from andys8/bugfix/4_no_login_error
Browse files Browse the repository at this point in the history
Show login error message if credentials are wrong
  • Loading branch information
Richard Feldman authored Feb 1, 2018
2 parents f964893 + 60767fe commit 887653b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Page/Login.elm
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,8 @@ modelValidator =

errorsDecoder : Decoder (List String)
errorsDecoder =
decode (\email username password -> List.concat [ email, username, password ])
decode (\emailOrPassword email username password -> List.concat [ emailOrPassword, email, username, password ])
|> optionalError "email or password"
|> optionalError "email"
|> optionalError "username"
|> optionalError "password"
Expand Down

0 comments on commit 887653b

Please sign in to comment.