diff --git a/examples/pokedex/app/Page/Login.elm b/examples/pokedex/app/Page/Login.elm index 206fbb72..3c02a45e 100644 --- a/examples/pokedex/app/Page/Login.elm +++ b/examples/pokedex/app/Page/Login.elm @@ -54,7 +54,7 @@ data routeParams = |> Result.withDefault Nothing |> Maybe.withDefault Session.empty |> Session.insert "name" name - |> Session.withFlash2 "message" ("Welcome " ++ name ++ "!") + |> Session.withFlash "message" ("Welcome " ++ name ++ "!") , "/greet" |> Server.Response.temporaryRedirect ) diff --git a/src/Server/Session.elm b/src/Server/Session.elm index 87f7e329..99e3c0f7 100644 --- a/src/Server/Session.elm +++ b/src/Server/Session.elm @@ -1,8 +1,8 @@ -module Server.Session exposing (Decoder, NotLoadedReason(..), Session(..), Value(..), clearFlashCookies, empty, expectSession, flashPrefix, get, insert, remove, setValues, succeed, unwrap, update, withFlash2, withSession) +module Server.Session exposing (Decoder, NotLoadedReason(..), Session(..), Value(..), clearFlashCookies, empty, expectSession, flashPrefix, get, insert, remove, setValues, succeed, unwrap, update, withFlash, withSession) {-| -@docs Decoder, NotLoadedReason, Session, SessionUpdate, Value, clearFlashCookies, empty, expectSession, flash, flashPrefix, get, insert, noUpdates, oneUpdate, remove, setValues, succeed, unwrap, update, updateAllFields, withFlash, withFlash2, withSession +@docs Decoder, NotLoadedReason, Session, SessionUpdate, Value, clearFlashCookies, empty, expectSession, flash, flashPrefix, get, insert, noUpdates, oneUpdate, remove, setValues, succeed, unwrap, update, updateAllFields, withFlash, withFlash, withSession -} @@ -36,8 +36,8 @@ type Value {-| -} -withFlash2 : String -> String -> Session -> Session -withFlash2 key value (Session session) = +withFlash : String -> String -> Session -> Session +withFlash key value (Session session) = session |> Dict.insert key (NewFlash value) |> Session