Skip to content

Conversation

@Just-Roman
Copy link
Collaborator

No description provided.

@Just-Roman Just-Roman requested review from Kotezh and Slavakorgg May 13, 2025 09:59

private static final String ACTIVITY_REVIEW_CREATE = ACTIVITY_GENERAL +
"""
VALUES(:userId, :entityId, 'REVIEW', 'ADD',
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'REVIEW', 'ADD' и пр.
все строки нужно вынести в константы.
Это позволит их хранить в одном месте и избежать опечаток при использовании

Copy link
Owner

@Kotezh Kotezh May 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

можно каждую строчку в константу, а лучше создать enum, например:

public enum EventType {
    LIKE,
    FRIEND,
    REVIEW
}

public enum OperationType {
    ADD,
    UPDATE
    REMOVE
} 

@Just-Roman Just-Roman merged commit b0ea79f into develop May 14, 2025
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.

4 participants