MCPcopy Create free account
hub / github.com/bwapi/bwapi / traverse

Function traverse

Documentation/post-processing/modify_dom.js:76–87  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

74}
75
76function traverse(path) {
77 if (fs.isFile(path) && /\.html$/.test(path)) {
78 modifyPage(path);
79 } else if (fs.isDirectory(path) && !fs.isLink(path)) {
80 var files = fs.list(path);
81 for (var i = 0; i < files.length; ++i) {
82 if (files[i] != "." && files[i] != "..") {
83 traverse(path + "/" + files[i]);
84 }
85 }
86 }
87}
88
89traverse(system.args[1]);
90phantom.exit();

Callers 1

modify_dom.jsFile · 0.85

Calls 1

modifyPageFunction · 0.85

Tested by

no test coverage detected