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

[MODEL] Add "suggest" method to get response suggest #483

Closed
wants to merge 3 commits into from

Conversation

nipe0324
Copy link
Contributor

I would like to use suggest of Elasticsearch response.
But Elasticsearch::Model::Response::Response class hasn't the method. That's why I added it.

I have already signed the CLA.

@karmi
Copy link
Contributor

karmi commented Oct 25, 2015

I think it makes sense. Can we also have integration tests for the feature, and update to the example application HTML template (in a separate commit?)

@karmi karmi added the waiting label Oct 25, 2015
@karmi
Copy link
Contributor

karmi commented Oct 25, 2015

Some tests on Travis are failing, do they run locally for you?

@nipe0324
Copy link
Contributor Author

I fixed it.

@karmi karmi closed this in e9052ae Jan 22, 2016
karmi pushed a commit that referenced this pull request Jan 22, 2016
karmi added a commit that referenced this pull request Jan 22, 2016
@karmi
Copy link
Contributor

karmi commented Jan 22, 2016

I'm sorry for such a long delay, I've tweaked the code a bit and merged it! Thanks!

karmi added a commit that referenced this pull request Jan 22, 2016
Refactored the accessor for the `suggest` part of the response introduced in #483
to allow a richer interface.

Added a `terms` helper method which just returns a flat array of

    response.suggestions.terms
    # => [ 'Foo', 'Bar' ]

Related: rubygems/rubygems.org#1135
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants