Skip to content

Disabling callbacks based on Expression language #21

Description

@tristanbes

Hello,

Right now we can disable a callback via enabled: false.
Wouldn't be awesome if we could put Expressions using the ExpressionEngine instead of a boolean ?

Use case: feature flags
This way we could enable/disable callbacks with business logic instead of adding the logic itself inside the callback code wenever possible.

callbacks:
    my_callback:
        ...
        enabled: "object.getSettings().hasFeature('email_enabled')"

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

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions