mirror of
https://github.com/jazzband/django-fernet-encrypted-fields.git
synced 2026-03-16 22:40:27 +00:00
Fixed getting SECRET_KEY_FALLBACKS for django <4.1
This commit is contained in:
parent
3e934dc86e
commit
05be6f7bc4
1 changed files with 1 additions and 1 deletions
|
|
@ -28,7 +28,7 @@ class EncryptedFieldMixin:
|
|||
if isinstance(settings.SALT_KEY, list)
|
||||
else [settings.SALT_KEY]
|
||||
)
|
||||
secret_keys = [settings.SECRET_KEY] + (settings.SECRET_KEY_FALLBACKS or [])
|
||||
secret_keys = [settings.SECRET_KEY] + getattr(settings, "SECRET_KEY_FALLBACKS", list())
|
||||
for secret_key in secret_keys:
|
||||
for salt_key in salt_keys:
|
||||
salt = bytes(salt_key, "utf-8")
|
||||
|
|
|
|||
Loading…
Reference in a new issue