synrc / n2o

⭕ N2O: Distributed WebSocket Application Server ISO 20922
https://ws.n2o.dev
Other
1.34k stars 168 forks source link

Fix http 500 error when setting Cookies #303

Closed Spoowy closed 6 years ago

Spoowy commented 6 years ago

n2o_cx:add_cookie(Name,Value,Path,TTL) can only handle list values for Name and Value. Feeding an atom name will result in a http 500 error.

Encapsulating Name and Value in _tolist() fixes the issue: n2o_cx:add_cookie(to_list(Name),to_list(Value),Path,TTL)

5HT commented 6 years ago

Doesn't accept.