Skip to content

fix: add WIFI_PRIVACY guard to savePreferences debug log - #291

Merged
melkati merged 1 commit into
developmentfrom
fix/savepreferences-debug-guard
Jul 9, 2026
Merged

fix: add WIFI_PRIVACY guard to savePreferences debug log#291
melkati merged 1 commit into
developmentfrom
fix/savepreferences-debug-guard

Conversation

@melkati

@melkati melkati commented Jul 9, 2026

Copy link
Copy Markdown
Owner

What

One-line fix: change #ifdef DEBUG_CAPTIVE_PORTAL to #if defined(DEBUG_CAPTIVE_PORTAL) && !defined(WIFI_PRIVACY) on the savePreferences endpoint debug log.

Why

The /savePreferences debug log in CO2_Gadget_WIFI.h:1860 is gated only by DEBUG_CAPTIVE_PORTAL, while other similar debug logs (printActualSettings(), onWifiSettingsChanged()) also respect the WIFI_PRIVACY flag. This aligns the guard for consistency.

Files changed

  • CO2_Gadget_WIFI.h - line 1860: preprocessor guard fix
  • platformio.ini - version bump: 015-beta -> 016-beta
  • CHANGELOG.md - new entry for v0.16.016-beta

Closes #290

The savePreferences debug log is currently gated only by
DEBUG_CAPTIVE_PORTAL, while other similar debug logs in the codebase
(printActualSettings, onWifiSettingsChanged) also check WIFI_PRIVACY.

Align the guard for consistency: change #ifdef to
#if defined(DEBUG_CAPTIVE_PORTAL) && !defined(WIFI_PRIVACY).

Bump version to 0.16.016-beta.

Closes #290
Copilot AI review requested due to automatic review settings July 9, 2026 07:00
@melkati
melkati merged commit 5a360ad into development Jul 9, 2026
1 check passed

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.

Pull request overview

This PR aligns /savePreferences serial debug output with the project’s WIFI_PRIVACY expectations by ensuring the debug log is suppressed when privacy mode is enabled, while also bumping the development version and documenting the fix in the changelog.

Changes:

  • Guarded the /savePreferences debug log with !defined(WIFI_PRIVACY) in addition to DEBUG_CAPTIVE_PORTAL.
  • Bumped the build revision from 015-beta to 016-beta.
  • Added a changelog entry for v0.16.016-beta describing the privacy-guard fix.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
CO2_Gadget_WIFI.h Updates the preprocessor guard so /savePreferences debug output won’t print when WIFI_PRIVACY is enabled.
platformio.ini Version/revision bump to 016-beta to reflect the new build iteration containing the fix.
CHANGELOG.md Documents the fix under the new v0.16.016-beta Unreleased entry.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

savePreferences debug log does not respect WIFI_PRIVACY flag

2 participants