lib/ServeClientFiles/ClientDirWatcher.js
function generateCache(filePath) {
    var id = generateIdFromFilePath(filePath);
    Debug._l(id);
    fs.readFile(filePath, 'utf8', function (err, data) {
        if (err) {
            Debug._l("err: " + err);
            return;
        }
        fs.stat(filePath, function (err, stat) {
            setCache(id, {modified:stat.mtime, content:data });
        });
    });
}
function generateCache(filePath) {
    var id = generateIdFromFilePath(filePath);
    Debug._l(id);
    fs.readFile(filePath, 'utf8', function (err, data) {
        if (err) {
            Debug._l("err: " + err);
            return;
        }
        fs.stat(filePath, function (err, stat) {
            setCache(id, {modified:stat.mtime, content:data });
        });
    });
}
function generateCache ( filePath ) { var id = generateIdFromFilePath ( filePath ) ; Debug . _l ( id ) ; fs . readFile ( filePath , 'utf8' , function ( err , data ) { if ( err ) { Debug . _l ( "err: " + err ) ; return ; } fs . stat ( filePath , function ( err , stat ) { setCache ( id , { modified : stat . mtime , content : data } ) ; } ) ; } ) ; }
Reads file and cache its data
@param id
@param filePath
Reads file and cache its data