Files
sim/apps/realtime
Waleed e98715da01 fix(realtime): noindex the socket server's 404 responses (#6129)
* fix(realtime): noindex the socket server's 404 responses

The sockets.* hostnames are served by this server and return a plain JSON
404, which Google Search Console reports as crawl errors. Mark unmatched
routes noindex so crawlers drop the hostnames instead of retrying them.

* fix(realtime): noindex every response, not just the 404

Setting the header only on the 404 fallback covered the one response that
crawlers already drop on status code alone, while /health — the sole route
returning 200 with a body, and so the only indexable surface on the socket
hostnames — stayed uncovered, with a test pinning it that way.

Set it once on the handler instead. Node merges setHeader values into
writeHead and no branch sets X-Robots-Tag, so it reaches every response.
2026-07-31 12:55:48 -07:00
..