Skip to content

Remove or document unused public API before 1.0 #27

Description

@loevgaard

Problem

The 1.0 release will be guarded by the Roave BC check, so everything public at that point becomes a commitment. A few things are public but unused:

  1. ConversionsApiEventRaised::$context and hasContext() (src/Event/ConversionsApiEventRaised.php:22). Nothing in the bundle reads the context, there is no getContext(), and the README does not mention it. Either document it as the way to pass information to application listeners (and add a typed getter) or remove it.
  2. Setono\MetaConversionsApiBundle\Message\Command\CommandInterface is an empty marker implemented by SendEvent and referenced nowhere. It can be useful for Messenger routing by interface (routing: { 'Setono\MetaConversionsApiBundle\Message\Command\CommandInterface': async }), but only if documented; otherwise remove it.
  3. Container parameters setono_meta_conversions_api.client_side.enabled and setono_meta_conversions_api.server_side.enabled (src/DependencyInjection/SetonoMetaConversionsApiExtension.php:29-30) are set but no service consumes them since services became conditional. Keep them only if they are meant as public flags for other bundles, and say so in the README or UPGRADE.md.
  4. ConversionsApiEventRaised::$event is a public mutable property. Consider public readonly Event $event (the Event object itself stays mutable) to make the intent clear.

Suggested fix

Decide per item before tagging 1.0, then document what stays. This avoids a 2.0 for cosmetic reasons.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions