Skip to content

Commit

Permalink
update devDependencies
Browse files Browse the repository at this point in the history
Highlight: spaces -> tabs shinnn/eslint-config@e92384d
  • Loading branch information
shinnn committed Dec 5, 2017
1 parent e012767 commit aeff529
Show file tree
Hide file tree
Showing 5 changed files with 3,220 additions and 3,227 deletions.
7 changes: 5 additions & 2 deletions .editorconfig
Expand Up @@ -3,10 +3,13 @@ root = true
[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
indent_style = tab
tab_width = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.{md,yml}]
indent_style = space

[*.md]
trim_trailing_whitespace = false
28 changes: 14 additions & 14 deletions index.js
Expand Up @@ -4,23 +4,23 @@ const enumerateFiles = require('enumerate-files');
const isFileUtf8 = require('is-file-utf8');

module.exports = async function listUtf8Files(...args) {
const paths = await enumerateFiles(...args);
const results = new Set();
const promises = new Set();
const paths = await enumerateFiles(...args);
const results = new Set();
const promises = new Set();

for (const path of paths) {
promises.add(isFileUtf8(path));
}
for (const path of paths) {
promises.add(isFileUtf8(path));
}

const pathIterator = paths.values();
const pathIterator = paths.values();

for (const isUtf8 of await Promise.all(promises)) {
const {value} = pathIterator.next();
for (const isUtf8 of await Promise.all(promises)) {
const {value} = pathIterator.next();

if (isUtf8) {
results.add(value);
}
}
if (isUtf8) {
results.add(value);
}
}

return results;
return results;
};

0 comments on commit aeff529

Please sign in to comment.