It seems to work when fetching data from DB, but stops working when I call a function like getTokenIdMetadata.
The second I switch back to the remotely hosted server, everything starts working again.
Did you thy that patch to add that app id?
Faced way to many errors trying to setup express. Too many changed required to make that patch work for me.
You only have to change in a file locally
Get the error 'app' is not defined
. What am I doing wrong here? Followed the exact instructions from the patch.
I think that you have to add server side that code, where you will find a similar code already
If you look in network tab for the payload of that request do you see the app id there?
Some do, some don’t. Even those that do, return empty.
Would it be possible, to DM you the API details, so you could troubleshoot yourself? We really need this fixed fast.
here is says client version 1.9.0 and not 1.12.0
I mean for when it doesn’t work with your self hosted server to look in the payload, not for when it works with your moralis server
The screenshot are with the local server. And I guess the 1.9 version is from the package.json
"moralis": "^1.9.0",
And I can’t change it, since moralis v1.12.0 doesn’t exists. I can only change the moralis-v1 to the new patch, but I already did that.
"moralis-v1": "^1.12.0",
can you try to build again in an empty folder? in case that there is some cached package from the past
this is the file where you have to add that patch server side:
The latest [email protected]
seems to have fixed this issue.
You need to install [email protected]
in order for it to use moralis-v1
instead of moralis
.
And then uninstall the older [email protected]
.
If you’re using any imports from Moralis in your code e.g. import Moralis from 'moralis'
then you would just change moralis
to moralis-v1
.
Thanks, this worked. But one extra issue popped up, all GET data request are now returning error 1. When I call any other request everything works fine, but when I try to fetch any data from DB I get an error.
Can you post this code where you try to fetch data.
And this happened only after you updated to [email protected]
?
I am not getting that issue when querying my parse
database with similar code. Can you try with a simpler query e.g. without the equalTo
and try querying a different class like UserListings.
Yes, it only started after I switched from moralis
to moralis-v1
. And it keep happening with all queries, even the simple ones. What’s strange is that the error is only prompted when I request valid data, but when I request data that’s not in the DB, no errors come up, and I get a valid response {"results":[]}