mirror of
https://github.com/S2-/minifyfromhtml.git
synced 2025-08-02 12:00:03 +02:00
remove streamToString
This commit is contained in:
@@ -25,16 +25,6 @@ if (!argv.js || !argv.css) {
|
||||
return;
|
||||
}
|
||||
|
||||
function streamToString(stream) {
|
||||
const chunks = []
|
||||
return new Promise((resolve, reject) => {
|
||||
stream.on('data', chunk => chunks.push(chunk))
|
||||
stream.on('error', reject)
|
||||
stream.on('end', () => resolve(Buffer.concat(chunks).toString('utf8')))
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
var excludeFiles = argv.exclude || [];
|
||||
if (typeof(excludeFiles) === 'string') {
|
||||
excludeFiles = [excludeFiles];
|
||||
|
Reference in New Issue
Block a user