Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add Mongo builder mixin to DocumentModel #3417

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

Merged
paulinevos merged 1 commit into mongodb:5.x from paulinevos:326_improve-type
Jul 2, 2025

Conversation

Copy link
Collaborator

@paulinevos paulinevos commented Jun 25, 2025

It helps with autocompletion as IDEs will recognize Mongo builder methods that are not present on the base builder.

Checklist

  • (削除) Add tests and ensure they pass (削除ここまで) N/A

@paulinevos paulinevos requested a review from a team as a code owner June 25, 2025 08:24
It helps with autocompletion as IDEs will recognize Mongo builder
methods that are not present on the base builder.
use function strlen;
use function var_export;

/** @mixin Builder */
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to remove the @mixin annotation from the Model class (#2981) because the return types of the methods is not the same in the Builder and the Model. I must have made a mistake.

@alcaeus alcaeus requested a review from GromNaN July 1, 2025 09:29
Copy link
Member

@GromNaN GromNaN left a comment
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make this change. It improves type understanding in PHPStorm. If a issue arises with Larastan, we will investigate it.

@paulinevos paulinevos merged commit 08d21aa into mongodb:5.x Jul 2, 2025
71 checks passed
@paulinevos paulinevos deleted the 326_improve-type branch July 2, 2025 06:49
@GromNaN GromNaN added this to the 5.5 milestone Aug 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@GromNaN GromNaN GromNaN approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
5.5
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /