[SOLVED] Error: "getNFTs Old" & not saving eth address

Hi, my app was working earlier, then I cleared my user table rows (all rows were just me testing) and now it isn’t connecting/working. Any ideas what may be happening? I noticed it is no longer pulling in the user eth address, which explains why no user-specific data pulls in. But not sure why it isn’t saving when it was earlier in the day.

The Error

My User Table

My Code

        const serverUrl = myServer;
        const appId = myAppID;
        Moralis.start({ serverUrl, appId });

        /* Moralis init code */
	async function login(){
	  console.log("login clicked");
          var user = await Moralis.Web3.authenticate();
          if(user){
              user.set("nickname","123");
              user.save();
           };
         }

The error in this image occurs as there is no logged in user or you haven’t added the address parameter in the getNFTs function.

If you are manually deleting the users from user table you need to make sure all the user related data from session and transaction table are removed.
https://docs.moralis.io/moralis-dapp/users/delete-user

1 Like

Oh yes, okay thank you! This fixed it :slight_smile: