index.js
function addCompressionToFile(filePath, compression) {
        var srcFilePath = filePath.replace(rootFolder, "").replace(compression.fileExtension, "");
        var existingFile = files[srcFilePath];
        if (!existingFile) {
            files[srcFilePath] = { compressions: [compression] };
        } else {
            existingFile.compressions.push(compression);
        }
    }
function addCompressionToFile(filePath, compression) {
        var srcFilePath = filePath.replace(rootFolder, "").replace(compression.fileExtension, "");
        var existingFile = files[srcFilePath];
        if (!existingFile) {
            files[srcFilePath] = { compressions: [compression] };
        } else {
            existingFile.compressions.push(compression);
        }
    }
function addCompressionToFile ( filePath , compression ) { var srcFilePath = filePath . replace ( rootFolder , "" ) . replace ( compression . fileExtension , "" ) ; var existingFile = files [ srcFilePath ] ; if ( ! existingFile ) { files [ srcFilePath ] = { compressions : [ compression ] } ; } else { existingFile . compressions . push ( compression ) ; } }
Adds the compression to the file's list of available compressions
@param {string} filePath
@param {Compression} compression
Adds the compression to the file s list of available compressions