check if the authenticated user id exists in the displayed document and if the displayed document id exists in the authenticated document. customs functions, logical actions. Help, please

Actions & Logic

Hello Friends,

I have the following problem:

I have a collection of profiles of various documents and in the documents there is a LIKE field which is a list that stores the IDs of the users that the owner of the document has liked. In other words, every like that a user makes is saved in the LIKE field (list) of their document.

I am trying to create a conditional that checks if the ID of the authenticated User exists in the LIKE field of the document of the user being displayed and if the ID of the user being displayed exists in the LIKE field of the document of the authenticated user. If so, it is supposed to match.

I have tried using actions, I have also tried using custom functions and it is not working. Right now after clicking the like, it is giving an error.

I am including the prints below:

What have you tried so far?

Did you check FlutterFlow's Documentation for this topic?
Yes
1
1 reply