Skip to content

fix: remove conflicting abstract method from Extension base class#1221

Merged
danieliser merged 1 commit into
developfrom
fix/extension-base-class-conflict
May 27, 2026
Merged

fix: remove conflicting abstract method from Extension base class#1221
danieliser merged 1 commit into
developfrom
fix/extension-base-class-conflict

Conversation

@danieliser

@danieliser danieliser commented May 27, 2026

Copy link
Copy Markdown
Member

Summary

  • Removes the duplicate abstract registered_controllers() declaration from PopupMaker\Plugin\Extension.
  • v2 extensions extend ExtensionContainer; the redeclared abstract method caused fatals during boot.

Test plan

  • Activate a v2 extension (Exit Intent, Scroll Triggers, or Scheduling) against core with this branch.
  • Confirm plugin boots without fatal errors.
  • Confirm extension controllers still register and frontend assets load.

Summary by CodeRabbit

  • Bug Fixes
    • Fixed a fatal error that occurred when loading v2 extensions.

Review Change Stack

Child extension cores extend Container via Extension; redeclaring
registered_controllers() as abstract caused fatals when v2 extensions boot.
@coderabbitai

coderabbitai Bot commented May 27, 2026

Copy link
Copy Markdown

Caution

Review failed

Pull request was closed or merged during review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 4f2c8251-3cc8-4d46-835b-48965d34028f

📥 Commits

Reviewing files that changed from the base of the PR and between 829cffb and 154b959.

📒 Files selected for processing (2)
  • CHANGELOG.md
  • classes/Plugin/Extension.php

Walkthrough

This PR fixes a fatal error when loading v2 extensions by removing a conflicting registered_controllers() method declaration from the Extension class. The Extension class's explicit abstract method declaration conflicted with the inherited declaration from Container, causing the error. The docstring is updated to clarify that subclasses should override the Container method instead.

Changes

Extension registered_controllers() conflict resolution

Layer / File(s) Summary
Remove duplicate method declaration and update documentation
classes/Plugin/Extension.php, CHANGELOG.md
Extension removes its explicit abstract protected registered_controllers() method declaration and updates the class docblock to direct child extensions to override Container::registered_controllers(). The changelog documents the bug fix for the fatal error caused by the conflicting declarations.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: removing a conflicting abstract method from the Extension base class, which directly addresses the fatal error issue described in the PR objectives.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/extension-base-class-conflict

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@danieliser danieliser merged commit b72d9dc into develop May 27, 2026
18 of 19 checks passed
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.

1 participant