Skip to content

Elasticsearch::Persistence::Repository#index_exists? silently drops arguments #852

Closed
@fnordfish

Description

@fnordfish

I was just upgrading and ran into an issues when trying to use my_repository.index_exists?(index: "my_index_name")

In https://github.com/elastic/elasticsearch-rails/blob/master/elasticsearch-persistence/lib/elasticsearch/persistence/repository.rb#L213-L215

While I can still pass in an explicit :index, all arguments are ignored and the repositories index_name is used instead.

This is a bit surprising, I would expect the method to either use the passed in argument or raise an ArgumentError if passing an index name is not desired.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions