Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const useMonitorsFetch = () => {
try {
const response = await networkService.getMonitorsByTeamId({
limit: null, // donot return any checks for the monitors
types: ["http", "ping", "port"], // status page is available for uptime, ping, and port monitors
types: ["http", "ping", "port", "game"], // include game servers in status page monitor selection
});
Comment on lines 15 to 18
Copy link

Choose a reason for hiding this comment

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

P2 | Confidence: High

  • The hardcoded array of monitor types creates maintenance risk, as future additions would require manual updates across multiple locations, potentially leading to inconsistencies. Consider defining monitor types in a shared constants file for better maintainability.
  • The updated comment removes previous context about supported monitor types, reducing clarity for future maintainers. Suggest updating the comment to include all supported types for better documentation.

setMonitors(response.data.data.monitors);
} catch (error) {
Expand Down