Skip to content

fix(#749): Type 0 WARNING thold_log records $warning_emails instead of $alert_emails - #792

Open
bmfmancini wants to merge 2 commits into
Cacti:developfrom
bmfmancini:fix/issue-749-warning-log-emails
Open

fix(#749): Type 0 WARNING thold_log records $warning_emails instead of $alert_emails#792
bmfmancini wants to merge 2 commits into
Cacti:developfrom
bmfmancini:fix/issue-749-warning-log-emails

Conversation

@bmfmancini

Copy link
Copy Markdown
Member

Summary

Fixes #749

The type 0 warning notification log entry in thold_functions.php was incorrectly recording $alert_emails and $alert_bcc_emails instead of $warning_emails and $warning_bcc_emails.

The mail was correctly sent to $warning_emails, but the thold_log call recorded the alert list. As a result, the threshold history UI showed the wrong recipients for all type-0 warning notifications.

Changes

In the type 0 (WARNING) thold_log call (~line 2582):

  • 'emails' changed from $alert_emails$warning_emails
  • 'bcc_emails' changed from $alert_bcc_emails$warning_bcc_emails

Testing

  • Verified the surrounding code path: the thold_mail call in this branch correctly uses $warning_emails / $warning_bcc_emails, so the log now matches the actual recipients.
  • Confirmed no other type-0 warning log blocks were affected.

…lert emails

The type 0 warning notification log entry was incorrectly recording
$alert_emails and $alert_bcc_emails instead of $warning_emails and
$warning_bcc_emails. The mail was correctly sent to the warning list,
but the threshold history UI showed the wrong recipients for all
type-0 warning notifications.
Copilot AI lite review requested due to automatic review settings August 17, 2026 02:45

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@bmfmancini
bmfmancini changed the base branch from main to develop August 17, 2026 02:46

@somethingwithproof somethingwithproof left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The warning-recipient correction is valid, but this branch also carries the unrelated three-line #789 threshold_value fix. Please drop those hunks, add a Cacti-Composer/Pest assertion that the sent and logged warning/BCC recipients match, and add the CHANGELOG entry. The branch currently has no CI result, so the behavior is unverified.

@somethingwithproof

Copy link
Copy Markdown
Member

This open PR currently has no CI checks registered on its head, and maintainer edits are disabled. Please enable maintainer edits or update/rebase the branch so the current pinned-Cacti integration and Pest workflows can run.

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.

Bug: Type 0 WARNING thold_log records $alert_emails instead of $warning_emails

3 participants