Skip to content

Commit

Permalink
fix favorites
Browse files Browse the repository at this point in the history
  • Loading branch information
r-southworth committed Nov 19, 2024
1 parent c9913b6 commit fd57263
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/posts/ViewUserFavorites.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,11 @@ export const ViewUserFavorites: Component = () => {
});

const data = await response.json();
console.log("Get user favorites: ", data);
if (data) {
if (data.type === "single") {
console.log(data);
setFavoritedItems(data.posts.body);
setFavoritedItems(data.posts);
setListName(data.list_name);
setListNumber(data.list_number);
setLoading(false);
Expand Down

0 comments on commit fd57263

Please sign in to comment.