Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix error if no cache tags was registered #191

Open
wants to merge 1 commit into
base: 4.x
Choose a base branch
from

Conversation

sfsmfc
Copy link

@sfsmfc sfsmfc commented May 15, 2024

If no cache tags was registered, stopCollectingCacheInfo() returns [null, null]. If we try to assign another tag 'element-api' on it, we get the following error: [Error] Attempt to modify property "tags" on null

This patch solves the problem.

Description

Related issues

If no cache tags was registered, stopCollectingCacheInfo() returns [null, null]. If we try to assign another tag 'element-api' on it, we get the following error:
[Error] Attempt to modify property "tags" on null

This patch solves the problem.
@sfsmfc sfsmfc requested a review from brandonkelly as a code owner May 15, 2024 14:59
@WHITE-developer
Copy link

@brandonkelly facing this issue too. Any update on it?

@LinneaHarts
Copy link

I'm getting this too on one of my Craft 5 sites but not others.

@LinneaHarts
Copy link

This patch works

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.

3 participants