unique-frame-title-after.js 290 B

12345678910111213
  1. function uniqueFrameTitleAfter(results) {
  2. var titles = {};
  3. results.forEach(r => {
  4. titles[r.data] = titles[r.data] !== undefined ? ++titles[r.data] : 0;
  5. });
  6. results.forEach(r => {
  7. r.result = !!titles[r.data];
  8. });
  9. return results;
  10. }
  11. export default uniqueFrameTitleAfter;