MCPcopy Index your code
hub / github.com/github/docs / middleware

Function middleware

middleware/block-robots.js:24–27  ·  view source on GitHub ↗
(req, res, next)

Source from the content-addressed store, hash-verified

22}
23
24const middleware = function blockRobots(req, res, next) {
25 if (blockIndex(req.path)) res.set('x-robots-tag', 'noindex')
26 return next()
27}
28
29middleware.blockIndex = blockIndex
30

Callers 1

createAppFunction · 0.85

Calls 2

blockIndexFunction · 0.85
nextFunction · 0.50

Tested by

no test coverage detected