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

comparator missing for find by id #266

Open
jchris opened this issue Feb 26, 2023 · 0 comments
Open

comparator missing for find by id #266

jchris opened this issue Feb 26, 2023 · 0 comments

Comments

@jchris
Copy link

jchris commented Feb 26, 2023

I am using a reduce-toolkit example app and getting errors. I am trying to update a Post in the mutations example app but get this error:

TypeError: comparatorFn is not a function
    at http://localhost:3000/static/js/bundle.js:32276:16
    at Array.reduce (<anonymous>)
    at http://localhost:3000/static/js/bundle.js:32245:41
    at Array.map (<anonymous>)
    at http://localhost:3000/static/js/bundle.js:32235:40
    at http://localhost:3000/static/js/bundle.js:32342:12
    at http://localhost:3000/static/js/bundle.js:32719:9
    at forEach (http://localhost:3000/static/js/bundle.js:32701:7)
    at Object.filter (http://localhost:3000/static/js/bundle.js:32718:3)
    at queryByPrimaryKey (http://localhost:3000/static/js/bundle.js:32340:24)

I think this is a problem with the data package, but the code to reproduce it is here.

here is a screenshot indicating the comparatorName is "0"

Screen Shot 2023-02-26 at 10 38 40 AM

Hope this helps someone fixing a similar issue!

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

No branches or pull requests

1 participant