make ready the add to favorite functionality

hi
i made some changes that now the add to favorite part is working
properly