Plug Broken In 1.7
aturkewi opened this issue · comments
Using the plug with the new version raises and error:
[error] #PID<0.542.0> running RegistrarWeb.Endpoint (cowboy_protocol) terminated
Server: localhost:4000 (http)
Request: GET /sadfasdf
** (exit) an exception was raised:
** (FunctionClauseError) no function clause matching in Map.from_struct/1
I believe is is associated to this change: https://github.com/fazibear/airbrakex/blob/master/lib/airbrakex/notifier.ex#L39
The plug returns errors as a map already and Map.from_struct/1
is expecting a struct.
I'll try and put a fix in if I can as I'm already working on putting in tests for the plug (so that I can add URLs to the context with the plug)
I've released another version.
Thank you for the fast turn around on this!