bleupen / halacious

a better HAL processor for Hapi
MIT License
108 stars 22 forks source link

Make use of additional custom onPreResponse extensions #88

Closed felixheck closed 8 years ago

felixheck commented 8 years ago

I have a custom onPreResponse extension adding an E-Tag header field to all my GET requests. I added this one via server.ext('onPreResponse, ...) but in combination with halacious this one is never executed. IMHO the response.send() (line 834 of plugin.js) is causing this issue.

Is there a possibility to solve the issue in a smart way? Do not wanna shift my extension to server.realm._extensions.onPreResponse manually.

felixheck commented 8 years ago

Okay..think it is done 🙈 Will use Glue's preRegister to register my extension before the plugins gets registered. Should world.