First, I would consider myself very new to Power Apps. I have been creating a Power App that is leveraged as a consumer portal to search for reports and datasets owned by my team. I am using the following code on a toggle (to favorite and unfavorite) to create new / update records in a Sharepoint list.
Patch('User Favorites',Defaults('User Favorites'),{Title:ThisItem.Title,Description:ThisItem.Description,'Report ID':ThisItem.ID,Link:ThisItem.'Analytics Link',Subject:ThisItem.'DataSubject (DataSubject0)',Date:Now(),User:User().FullName,Email:User().Email,Favorite:Toggle1_1.Value})
This is currently a new record for each time the toggle is used. I would like to update so that if a user has already favorited an item and they want to unfavorite it, it will update the sharepoint record vs. creating a new one. Current Sharepoint fields are ID, Description, Email, Favorite (... true or false based upon toggle), User, Link, Date, Subject.
Any help would be appreciated.