Skip to content

Commit 04d3dc1

Browse files
aclark4lifeJibola
andauthored
Update django_mongodb_backend/schema.py
Co-authored-by: Jib <Jibzade@gmail.com>
1 parent 29a1d97 commit 04d3dc1

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

django_mongodb_backend/schema.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -436,8 +436,7 @@ def _create_collection(self, model):
436436
client = self.connection.connection
437437
options = getattr(client._options, "auto_encryption_opts", None)
438438
if options is not None:
439-
schema_map = getattr(options, "_schema_map", None)
440-
if schema_map:
439+
if schema_map := getattr(options, "_schema_map", None)
441440
db.create_collection(db_table, encryptedFields=schema_map[db_table])
442441
else:
443442
key_vault_namespace = options._key_vault_namespace

0 commit comments

Comments
 (0)