Skip to content

Instantly share code, notes, and snippets.

@b0oh
Created April 12, 2019 13:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save b0oh/75cb5e4bca4f57f4c249da0981b4f930 to your computer and use it in GitHub Desktop.
Save b0oh/75cb5e4bca4f57f4c249da0981b4f930 to your computer and use it in GitHub Desktop.
funny.elm
zayoba : Decode.Value -> String
zayoba value =
let
decoder = Decode.map (Encode.encode 0) Decode.value
in
case Decode.decodeValue decoder value of
Ok result ->
result
_ ->
"zayoba"
yopta : Result Http.Error Decode.Value -> Message
yopta result =
case result of
Ok value ->
Authenticated (zayoba value)
Err reason ->
Qwe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment