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

Updated readme.md #65

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Updated readme.md #65

wants to merge 1 commit into from

Conversation

vmadman
Copy link

@vmadman vmadman commented Jun 22, 2013

The boolean query example used the query() method, which does not exist. Instead, it should use the queryBuilder() method. Additionally, if you pass a single parameter to must(), should(), or must_not().. then it will be iterated as though it is an array of classes that implement \Sherlock\components\QueryInterface.

Therefore, you cannot pass a Term() or Match() class directly to the must(), should(), or must_not() method as previously shown, but must wrap them in an array or pass multiple classes/queries.

The boolean query example used the query() method, which does not exist.  Instead, it should use the queryBuilder() method.  Additionally, if you pass a *single* parameter to must(), should(), or must_not().. then it will be iterated as though it is an array of class that implement \Sherlock\components\QueryInterface.

Therefore, you cannot pass a Term() or Match() class directly to the must(), chould(), or must_not() method as previously shown.
@vmadman
Copy link
Author

vmadman commented Jun 22, 2013

Sorry if I'm just being dumb here. I suspect that query() was replaced by queryBuilder() at some point?

@polyfractal
Copy link
Owner

Gah, sorry for letting this hang...I'm out of town at the moment. The Readme is definitely wrong (the name did indeed change from query to queryBuilder.

Sounds like a bug for must/should/must_not. I'll investigate when I get home

@wangxiaomo
Copy link

lgtm.

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