Hello,
In a resolver (phoenix) I want to use “conn”. (I want to get the IP address)
How should I do that?
def vote(params, _info) do
comment = Blog.Post.get_comment!(iparams.id)
comment
|> Ecto.Changeset.change(ip: conn.remote_ip) # get the user IP??
|> Repo.update
end