Skip to content

Commit

Permalink
minor tweaks 📝
Browse files Browse the repository at this point in the history
  • Loading branch information
derhuerst committed Dec 17, 2024
1 parent cc69ef5 commit 0ffae36
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion lib/find-in-tree.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@ const createFindInTree = (needles) => {
},
});

return (haystack) => {
const findInTree = (haystack) => {
const context = Object.create(null);
needles.forEach((needle) => {
context[needle] = [];
});
return scanner(haystack, context);
};
return findInTree;
};

export {
Expand Down
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
[![npm version](https://img.shields.io/npm/v/hafas-client.svg)](https://www.npmjs.com/package/hafas-client)
![ISC-licensed](https://img.shields.io/github/license/public-transport/hafas-client.svg)
[![support Jannis via GitHub Sponsors](https://img.shields.io/badge/support%20Jannis-donate-fa7664.svg)](https://github.com/sponsors/derhuerst)
[![chat with Jannis on Twitter](https://img.shields.io/badge/chat%20with%20Jannis-on%20Twitter-1da1f2.svg)](https://twitter.com/derhuerst)
[![chat with Jannis via Matrix](https://img.shields.io/badge/chat%20with%20Jannis-via%20Matrix-000000.svg)](https://matrix.to/#/@derhuerst:matrix.org)

**[documentation](docs/readme.md)**

Expand Down

0 comments on commit 0ffae36

Please sign in to comment.