I am noticing that my cookies are not being set when I perform put_resp_cookie() before a redirect.
conn
|> put_resp_cookie("shop", shop)
if (some_condition) do:
redirect conn, to: "/foo/bar"
In my controller function for /foo/bar, the cookie is not set. Is there a way to set the cookie?
conn
after setting the cookie?conn = conn |> put_resp_cookie(..)
? – Dogbertconn
directly while you are doing anif
after the pipe. – Dogbert