diff --git a/mongo/client_encryption.go b/mongo/client_encryption.go index 2f4ad8f8b7..dac55f52f0 100644 --- a/mongo/client_encryption.go +++ b/mongo/client_encryption.go @@ -82,10 +82,6 @@ func (ce *ClientEncryption) CreateEncryptedCollection(ctx context.Context, return nil, nil, errors.New("nil CreateCollectionOptions") } ef := createOpts.EncryptedFields - if ef == nil { - // Otherwise, try to get EncryptedFields from EncryptedFieldsMap. - ef = db.getEncryptedFieldsFromMap(coll) - } if ef == nil { return nil, nil, errors.New("no EncryptedFields defined for the collection") }