Skip to content

Conversation

@nickeskov
Copy link
Collaborator

This pull request refactors the Message() method in the BaseTargetAlert struct to improve string formatting and error handling. The method now uses a strings.Builder for more efficient string construction and includes explicit error checks after each formatting operation.

String formatting and error handling improvements:

  • Refactored the Message() method in BaseTargetAlert to use a strings.Builder for efficient string concatenation and added error handling with panics if formatting fails, ensuring that unexpected formatting errors are surfaced immediately. (pkg/entities/alerts.go)

@alexeykiselev alexeykiselev merged commit 2426096 into main Dec 13, 2025
13 checks passed
@alexeykiselev alexeykiselev deleted the modernize-fix branch December 13, 2025 08:43
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.

3 participants