Conversation
- Prevents banned users from reporting messages and disallows reporting messages from admins or room owners. - Introduces a dependency on `RoomService` to verify user privileges and enforces stricter validation for reporting logic.
- Optimizes the retrieval of user display names by handling only two users per direct chat. - Adds fallback names for unknown users and ensures the current user is always second in the order. - Enhances clarity and consistency in user identification for direct chats.
Enhance Chat Display Logic and Enforce Report Restrictions
…cing project documentation
- Overhauls the README file with a cleaner structure, improved formatting, and added icons for better readability. - Introduces a table of contents, reorganized sections, and detailed explanations of features, setup, and APIs. - Reduces verbosity by replacing lists with tables and collapsible sections. - Enhances navigation and usability for developers.
Enhance README documentation and structure
Fix README index formatting and refactor JoinRoom method
Comment out private room check in AddMemberToRoom method
Comment out user permission check in ReadPump method
Uncomment room join logic in ReadPump method
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces significant updates to the
README.mddocumentation, refactors several repository and service methods, and temporarily disables certain access control checks in the WebSocket and room management logic. Below is a summary of the most important changes:Documentation Enhancements
README.mdwith a more structured format, including new sections like "Tecnologías principales," "Endpoints," and "Implementación técnica." Added emojis and tables for better readability and user experience.WebSocket and Room Access Control
RoomRepository(AddMemberToRoom) and WebSocketReadPumpmethods, effectively allowing unrestricted room joining for now. [1] [2]CanJoinRoomWebSocketcheck inRoomService'sJoinRoommethod, bypassing user validation for room access.Direct Chat Improvements
DirectChatRepositoryto handle user display names more robustly, ensuring that the current user is always listed second in theUserIDsandDisplayNamesarrays. Added fallback display names for unknown users.Moderation Enhancements
ModerationServiceto include checks for banned users and prevent reporting messages from admins or room owners. Added a dependency onRoomServicefor privilege validation. [1] [2] [3]These changes improve the project's documentation and user experience while temporarily relaxing access control for testing purposes. However, the disabled permission checks should be revisited before deployment to ensure proper security.