clearer .landscape.yml + change self.__class__._meta to self._meta
This commit is contained in:
parent
205a975781
commit
0189818f3e
@ -1,3 +1,4 @@
|
|||||||
pylint:
|
pylint:
|
||||||
disable:
|
disable:
|
||||||
- W0212
|
# We use this a lot (e.g. via document._meta)
|
||||||
|
- protected-access
|
||||||
|
@ -362,7 +362,7 @@ class Document(BaseDocument):
|
|||||||
else:
|
else:
|
||||||
select_dict = {}
|
select_dict = {}
|
||||||
select_dict['_id'] = object_id
|
select_dict['_id'] = object_id
|
||||||
shard_key = self.__class__._meta.get('shard_key', tuple())
|
shard_key = self._meta.get('shard_key', tuple())
|
||||||
for k in shard_key:
|
for k in shard_key:
|
||||||
path = self._lookup_field(k.split('.'))
|
path = self._lookup_field(k.split('.'))
|
||||||
actual_key = [p.db_field for p in path]
|
actual_key = [p.db_field for p in path]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user