Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

data.tags.split fix #88

Merged
merged 1 commit into from
Jul 13, 2022
Merged

data.tags.split fix #88

merged 1 commit into from
Jul 13, 2022

Conversation

youliao
Copy link
Contributor

@youliao youliao commented Jul 11, 2022

Tags is empty string:

https://konachan.com/post.json?tags=id:38805

Example:
const results = await Booru.search("konac", "id:38805");

Then throw error:

TypeError: Cannot read properties of undefined (reading 'split')
at getTags (/usr/src/node_modules/booru/dist/structures/Post.js:1:900)
at new Post (/usr/src/node_modules/booru/dist/structures/Post.js:1:2165)
at /usr/src/node_modules/booru/dist/boorus/Booru.js:1:2633
at Array.map ()
at Booru.parseSearchResult (/usr/src/node_modules/booru/dist/boorus/Booru.js:1:2625)
at Booru.search (/usr/src/node_modules/booru/dist/boorus/Booru.js:1:927)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)...

@AtoraSuunva AtoraSuunva self-requested a review July 13, 2022 02:21
@AtoraSuunva AtoraSuunva merged commit 5145679 into AtoraSuunva:master Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants