Unfavorite function

Hi all, I have added favorite functionality in my app and un-favorite as well but when I delete all the content in the list, in the end it is throwing me this error. This error also fires when I re-open favorite page second time(when content is there, I have created an empty list to display message but it doesn’t work for the second time)

image
Below are my blocks in Favorite page-

image


Kindly let me know in case any other screenshots are required.

Thanks for helping :slight_smile:

Try to initialize global index to 0.

blocks(1)

Result?

Also share a screenshot of show procedure.

Thanks for replying back!
I tried the suggested method and still the error is thrown.
The reason why I considered is because from empty tinydb, I am creating a list of ‘No fav yet’. If you can suggest something else, I can try that also.

As requested
image

Can you share AIA?

This is still work in progress but here you go-
finaln_aia.aia (13.6 KB)

Kindly let me know your suggestions.

Ok, atfer some working with your project, here’s the solution.
You have to change your delete button and show procedure in fav screen like this:

blocks(3)

Or simply drag and drop in the blocks section :wink:

2 Likes

Thank you sooo much! I wasted 3 days working on it and you helped me fix it in few minutes.

2 Likes

Glad to help you!

It’s always good practice to try to solve the problem yourself.
But if you stuck somewhere, remember that community is always here to help you. :slightly_smiling_face:

Keep Koding :+1:

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.