Closed mmrobins closed 4 years ago
I'm not quite clear what the problem you are trying to fix is.. Your description says it can't handle if another middleware is ahead of the instrumentation, but the change to the test schema is adding a middleware after the instrumentation...
Not ahead of instrumentation, can't handle if any middleware is ahead of the {Absinthe.Resolution, :call}
.
The current implementation on master assumes that Absinthe.Resolution
is the first thing on the middleware list %{middleware: [{{Absinthe.Resolution, :call}, resolver_fn} | _]} = res
, and it often won't be. Auth middleware for example.
I'm having this same issue too, could we resolve the conflicts and get it merged? 🙏 I'm here to help if that's needed
I fixed the merge conflict, was just a whitespace change. I'm no longer working in a elixir codebase, so I've not checked this as working like I originally did months ago.
@mmrobins I've tested this and works as expected, thanks! 🎉
Currently the pattern matching on
call
function can't handle if any middleware is ahead of the{Absinthe.Resolution, :call}
middleware.