Closed lostintangent closed 7 years ago
@philliphoff This may have been fixed by some of the latter header tracking work you did? It it did we should confirm the fix or fix this up. I suspect that the issue is that .type(".html")
isn't adding/setting the content type header into the headers list.
While I have yet to reproduce this particular issue with the latest bits (v0.15.2), I did find another issue where the HUD wasn't being injected when using res.type('.html')
, due to it generating a "complex" Content-Type
header that the HUD injection component does not properly parse. That's filed as Glimpse.Node#644;
If it turns out that this might have been fixed, lets close this off once we are sure.
p.s. good find on Glimpse.Node#644.
I'm unable to repro this on current bits. @lostintangent - if this still repros for you, could you include a zip of a small project that repros the problem?
Repro steps:
res.type(".html")
to a non-terminating middleware (i.e. one thats callsnext()
), assuming that the terminating middleware is callingres.render
.Expected: To just see the request for the root document Actual: I see requests for CSS and JS files as well
If I removed the call to
res.type
, and re-run the app, then everything displays in Glimpse as expected. This issue is pretty bizarre, and probably low-pri, but it's an example of how the filtering logic seems to get tripped up in some scenario, that an app could get into pretty easily.