Skip to content

The subscription type "" does not exist #95

@Kahmoon

Description

@Kahmoon

Hi Kamil,

i am managin subscribers via backend a lot. Sometimes it happens that there is created an "empty" subscription, which causes the complete website to crash if this event is listed. Var/logs contains the following error.

[2022-12-21T18:23:42.677219+01:00] request.CRITICAL: Uncaught PHP Exception InvalidArgumentException: "The subscription type "" does not exist" at /homepages/46/xxx/htdocs/xxx-v3/vendor/codefog/contao-events_subscriptions/src/Codefog/EventsSubscriptions/SubscriptionFactory.php line 52 {"exception":"[object] (InvalidArgumentException(code: 0): The subscription type \"\" does not exist at /homepages/46/xxx/htdocs/xxx-v3/vendor/codefog/contao-events_subscriptions/src/Codefog/EventsSubscriptions/SubscriptionFactory.php:52)"} []

At some state of the registration process there is created an entry without any "type". I cannot reproduce it. Probably it comes from creating a new subscription and abort before completing the process. This could explain why its neither guest or member at the current state. But its written to database to early isn´t it?

I have to remove this entry manually directly in the database. There is no other way.

How can we avoid this? Any idea?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions