It is ok if the directory doesn't exist.
parent
e0930005c3
commit
3b2a3ad324
|
@ -202,7 +202,11 @@ function statFile(filename, callback) {
|
||||||
if (error.code == "ENOENT") { // Stat the directory instead.
|
if (error.code == "ENOENT") { // Stat the directory instead.
|
||||||
fs.stat(path.dirname(ROOT_DIR + filename), function (error, stats) {
|
fs.stat(path.dirname(ROOT_DIR + filename), function (error, stats) {
|
||||||
if (error) {
|
if (error) {
|
||||||
|
if (error.code == "ENOENT") {
|
||||||
|
callback(null, null, false);
|
||||||
|
} else {
|
||||||
callback(error);
|
callback(error);
|
||||||
|
}
|
||||||
} else if (filename == 'js/require-kernel.js') {
|
} else if (filename == 'js/require-kernel.js') {
|
||||||
callback(null, stats.mtime.getTime(), true);
|
callback(null, stats.mtime.getTime(), true);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue