MCPcopy Create free account
hub / github.com/browserslist/browserslist / pathInRoot

Function pathInRoot

node.js:106–113  ·  view source on GitHub ↗
(p)

Source from the content-addressed store, hash-verified

104}
105
106function pathInRoot(p) {
107 if (!process.env.BROWSERSLIST_ROOT_PATH) return true
108 var rootPath = path.resolve(process.env.BROWSERSLIST_ROOT_PATH)
109 if (path.relative(rootPath, p).substring(0, 2) === '..') {
110 return false
111 }
112 return true
113}
114
115function check(section) {
116 if (Array.isArray(section)) {

Callers 1

eachParentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected