docs: function readDir (dir, regex = /^(?:)$/) {
    return new Promise((resolve, reject) =>
      fs.readdir(dir, (err, files) => err
        ? reject(err)
        : resolve(Promise.all(files.map(checkFileName.bind(null, dir, regex))))))
      .then(values =>
        [].concat(...values)
          .filter(i => i))
  }