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: permit makeSearchableUsing to realy modify the collection #808

Closed
wants to merge 1 commit into from

Conversation

ArnaudBan
Copy link

The makeSearchableUsing method is aime for modifying the collection.

I wanted to use the load method on my current collection but for that it need to assign the return to the current object.

Without this changes you can't really modify the collection, all modifications are not passe to the last call ->update($this->models)

@driesvints
Copy link
Member

There's no tests here.

@ArnaudBan
Copy link
Author

You are of course rigth. I will try to add tests as soon as i find how to do that. If you have some documentation to setup this package on my machine and run the tests it would help me a lot otherwise a will find how to do this. Thank you.

@taylorotwell
Copy link
Member

Sorry, I'm not sure why they wouldn't be modified? The load method loads the relationships onto the model instance and objects are by-reference in PHP.

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