Created
November 2, 2017 19:38
-
-
Save bsima/6844909f34d6bfd58423c3cef55ef4f8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case msg of | |
AddUserResponse newUsers -> | |
let | |
(newUserList, cmd) = | |
RemoteData.update \(ls -> (List.append ls newUsers, Cmd.none)) model.users | |
in | |
( { model | users = newUserList }, cmd ) | |
---- | |
case msg of | |
AddUserResponse newUsers -> | |
let | |
appendRemoteUsers ls = | |
RemoteData.Success <. List.append ls newUsers | |
in | |
( { model | users = RemoteData.andThen appendRemoteUsers model.users }, Cmd.none) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment