Skip to content

Feat/integrate profile posts#291

Merged
Kaylahray merged 2 commits intogeevapp:mainfrom
robertocarlous:feat/Integrate-profile-posts
Apr 26, 2026
Merged

Feat/integrate profile posts#291
Kaylahray merged 2 commits intogeevapp:mainfrom
robertocarlous:feat/Integrate-profile-posts

Conversation

@robertocarlous
Copy link
Copy Markdown
Contributor

@robertocarlous robertocarlous commented Apr 25, 2026

Closes #276

Summary

This PR updates the profile page to use the dedicated user-specific posts endpoint instead of relying on the generic posts endpoint with query parameters.

Problem

The profile page previously fetched data from:

/api/posts?userId=...

This approach relied on a contract that is not guaranteed by the generic posts endpoint, leading to inconsistent data handling and tight coupling to an unreliable response shape.

What Was Done

Switched profile page data fetching to:

GET /api/users/[id]/posts
Removed dependency on /api/posts?userId=...
Normalized API response to align with PostCard component requirements
Updated data mapping logic to ensure consistent rendering
Result
Profile page now consumes a stable, dedicated API contract
Improved reliability and maintainability of post data fetching
Reduced assumptions about backend response structure
Verification
Profile page successfully fetches posts from GET /api/users/[id]/posts
Posts render correctly using PostCard
Follow/unfollow functionality remains intact
Tab filters (posts, replies, media, etc.) work as expected with server data

@drips-wave
Copy link
Copy Markdown

drips-wave Bot commented Apr 25, 2026

@robertocarlous Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@3m1n3nc3
Copy link
Copy Markdown
Contributor

Closes #276

Please update your PR message and add a proper description of all the changes you made.

@robertocarlous
Copy link
Copy Markdown
Contributor Author

Pls check

@Kaylahray Kaylahray merged commit 3f32c75 into geevapp:main Apr 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Integrate profile posts fetch with dedicated user posts API

3 participants