Skip to content
This repository has been archived by the owner on Dec 2, 2020. It is now read-only.

Commit

Permalink
Update website.js
Browse files Browse the repository at this point in the history
Compatibility update for node-watch 0.5
  • Loading branch information
hellcatz committed Apr 22, 2017
1 parent 6937e7b commit 03e141d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libs/website.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,13 +95,13 @@ module.exports = function(logger){
};


//If an html file was changed reload it
watch('website', function(filename){
// if an html file was changed reload it
/* requires node-watch 0.5.0 or newer */
watch(['./website', './website/pages'], function(evt, filename){
var basename = path.basename(filename);
if (basename in pageFiles){
console.log(filename);
readPageFiles([basename]);
logger.debug(logSystem, 'Server', 'Reloaded file ' + basename);
logger.special(logSystem, 'Server', 'Reloaded file ' + basename);
}
});

Expand Down

0 comments on commit 03e141d

Please sign in to comment.