Skip to main content

User Reporting And Blocking

Quick Answer

The user reporting module lives in src/core/user-reporting. It lets users block or report other users and gives chat, feed, profile, video chat, and social graph features a shared way to filter blocked users.

Apps with user-generated content should keep this module enabled and production-tested before store submission.

Source Map

src/core/user-reporting
├── api
├── firebase.ts
├── index.ts
└── redux

Important exports:

ExportPurpose
useUserReportingReads blocked/reported user state.
useUserReportingMutationsBlocks, reports, or unblocks a user.
markAbuseLegacy compatibility function for creating a report.
unblockUserLegacy compatibility function for unblocking.

Firebase Data And Functions

The Firebase implementation uses collections and callable Functions similar to:

reports
user_reports/{userID}/reports_live
fetchBlockedUsers
markAbuse
unblockUser

Deploy the matching Firebase Functions before testing production blocking/reporting. Firestore rules should prevent users from reading or writing other users' moderation data directly unless the app intentionally exposes that data through safe, scoped paths.

Where It Is Used

User reporting is usually connected to:

  • chat and group chat;
  • video/audio calls;
  • social feed posts;
  • stories;
  • comments;
  • profile screens;
  • user search and friend lists;
  • marketplace/listing messages when users interact with each other.

When a user is blocked, related features should stop showing content and should prevent new direct interactions where appropriate.

Store Review Readiness

Before release, verify that user-generated content flows include:

  • a visible report or block action;
  • a way to unblock users if the app supports blocking;
  • backend records for moderation review;
  • filtering in feed/chat/user lists;
  • clear Terms of Use and privacy policy links;
  • a support contact path for abuse reports;
  • admin or operational process for reviewing serious reports.

Custom Backend

To use your own backend:

  1. Implement the same hook behavior in src/core/user-reporting/api/backend.
  2. Route report/block actions through authenticated endpoints.
  3. Store moderation events server-side.
  4. Return blocked users to the app so feed, chat, and profile screens can filter them.
  5. Add rate limiting and abuse prevention to report endpoints.
  6. Keep audit data for moderation operations.

Verification Checklist

Test:

  • user A reports user B;
  • user A blocks user B;
  • user B disappears from chat/feed/search where expected;
  • user A can unblock user B if that flow exists;
  • self-reporting or self-blocking is prevented;
  • permission-denied errors do not leave infinite loading;
  • moderation records are visible to your admin/support process.

Troubleshooting

ProblemFix
Block button appears to do nothingConfirm Firebase Functions are deployed and callable by the signed-in user.
Blocked users still appear in chat/feedCheck that the consuming module subscribes to blocked users and filters results.
Blocked users screen loads foreverReturn an empty list on listener error and inspect Firestore rules.
Users can modify report records directlyTighten Firestore rules and move writes through callable Functions.
Store review asks for UGC moderationShow block/report UI, Terms of Use, support contact, and moderation process.