Forums Feature Requests Thread

[Enhancement] Cross-cutting infra: Orphaned partial: adsense-sidebar.php (only self-documenting include in its own docblock)

Patrick Bass · Jun 6 · 10 · 1 Locked
[Normal Priority] [Feature Enhancement] [Deployed to Production]
🚀 OP Jun 6, 2026 8:05pm

Area: Cross-cutting infra (audit p14) · Surface: platform/templates/partials/adsense-sidebar.php · Dimension: deadcode · Severity: minor

templates/partials/adsense-sidebar.php is a never-wired AdSense gutter-ad partial documented as a planned upgrade. No page template includes it, so the right-gutter AdSense slot never renders even when analytics.adsense_client_id + adsense_slot_sidebar are configured.

Evidence

`$ grep -rn "adsense-sidebar" src/ templates/ public/ bin/ --include=*.php | grep -v 'templates/partials/adsense-sidebar.php:'` → (empty). The only include of this file is the EXAMPLE inside its own docblock at adsense-sidebar.php:14 (`<?php include BASE_PATH . '/templates/partials/adsense-sidebar.php'; ?>`). No real template includes it. Its own header (line 3) calls it "planned-upgrade #10".

Suggested fix. If AdSense gutter ads are still planned, include this partial from the relevant layout/sidebar (gated as it already self-gates on config). Otherwise delete templates/partials/adsense-sidebar.php — it is currently inert.

Filed by the automated tenant-app audit and adversarially evidence-verified. Status: verified. Open — not yet actioned.


Patrick Bass
@mobieus

🚀 Jun 7, 2026 10:24am

Resolved and deployed. Commit ca230723ea.

templates/partials/adsense-sidebar.php deleted — never included by any page template; only referenced in its own docblock example.

Closed as: shipped.


Patrick Bass
@mobieus

Log in or register to reply to this thread.