Skip to content

Fix method calls in BreadcrumbService#3

Open
infabo wants to merge 1 commit intoteamnovu:mainfrom
infabo:patch-1
Open

Fix method calls in BreadcrumbService#3
infabo wants to merge 1 commit intoteamnovu:mainfrom
infabo:patch-1

Conversation

@infabo
Copy link
Copy Markdown

@infabo infabo commented Mar 27, 2026

Pull request

A call to $entry->parent returns an AugmentedCollection in Statamic v6. $entry->collection() instead of $entry->collection (which is a protected property). I think it should always have been a method call - even in Statamic v5.

Creators Checklist

Thanks for your Contribution 🎉

Before you request a review, please check the following:

  • If you worked on a Jira Task: did you move the task to the review state?
  • If you worked on a Jira Task: did you name the PR containing the task ID?
  • Did you fullfill the business case? (Check the Jira task again to be sure).
  • Did you cleanup your codebase (remove unused and commented code, remove dumps, ray usages and console logs)?
  • If needed: did you write any tests and do they pass?
  • Did you push the latest changes?
  • Did you check for merge conflicts?

Reviewers Checklist

This list should help you to review your pull request:

  • Did you check the code is readable and maintainable (complexity!)?
  • Did you check code and comments for typos?
  • If possible: did you check the code matches the requested business case?
  • Did all tests pass?
  • For big PRs: Did you smoke test it in your local test environment?

After the PR is merged:

  • Did you delete the PR branch?
  • Did you mark the Jira task as done?
  • Was the deployment successful?

Note

Fix property access to use method calls in BreadcrumbService

Corrects incorrect direct property access in BreadcrumbService.php by replacing it with proper method calls. $entry->collection->mount() becomes $entry->collection()->mount(), and $entry->parent becomes $entry->parent() in the parent traversal loop.

Macroscope summarized 42aefe3.

@infabo infabo changed the title Fix entry method calls in BreadcrumbService Fix method calls in BreadcrumbService Mar 27, 2026
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.

1 participant