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

Add mget #64

Merged
merged 9 commits into from
Mar 2, 2021
Prev Previous commit
Allows in the bulk method to indicate the index only in the signature
carlosgalvez-tiendeo committed Mar 2, 2021
commit c8aa31d35feedc29806e949b3c0792b6815d9ffb
2 changes: 1 addition & 1 deletion elasticmock/fake_elasticsearch.py
Original file line number Diff line number Diff line change
@@ -352,7 +352,7 @@ def bulk(self, body, index=None, doc_type=None, params=None, headers=None):
action = next(iter(line.keys()))

version = 1
index = line[action]['_index']
index = line[action].get('_index') or index
doc_type = line[action].get('_type', "_doc") # _type is deprecated in 7.x

if action in ['delete', 'update'] and not line[action].get("_id"):