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

CraftCMS 3 - Update \craft\services\Fields::$_fetchedAllGroups when a new group is created #3102

Closed
joruro opened this issue Jul 16, 2018 · 2 comments

Comments

@joruro
Copy link

commented Jul 16, 2018

Please, update the \craft\services\Fields::$_fetchedAllGroups to false when a new group is created. Or add a method to reset it. Otherwise, when I try to get all the groups, I just that the groups that were fetched before creating the new one

@brandonkelly

This comment has been minimized.

Copy link
Member

commented Jul 16, 2018

Thanks for pointing that out - fixed for the next release.

Instead of setting $_fetchedAllGroups to false, saveGroup() now adds/updates the group's record in $_groupsById.

@joruro

This comment has been minimized.

Copy link
Author

commented Jul 17, 2018

Thanks. Note that I see this logic repeated on other services. For instance \craft\services\Volumes or \craft\services\Sections

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.