django-solomon 0.4.1__py3-none-any.whl → 0.4.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
django_solomon/apps.py CHANGED
@@ -6,6 +6,10 @@ class DjangoSolomonConfig(AppConfig):
6
6
  name = "django_solomon"
7
7
 
8
8
  def ready(self):
9
+ # Copyright (c) 2023 Carlton Gibson
10
+ # This migration is taken from the fantastic project `django-unique-user-email` created by Carlton Gibson.
11
+ # https://github.com/carltongibson/django-unique-user-email/
12
+
9
13
  from django.contrib.auth.models import User
10
14
  from django.db import models
11
15
 
@@ -16,11 +20,11 @@ class DjangoSolomonConfig(AppConfig):
16
20
  # But setting a constraint does not...
17
21
  User.Meta.constraints = [
18
22
  models.UniqueConstraint(
19
- name="unique_user_email",
20
23
  fields=["email"],
24
+ name="unique_user_email",
21
25
  # deferrable=models.Deferrable.DEFERRED,
22
26
  ),
23
27
  ]
24
28
  User._meta.constraints = User.Meta.constraints
25
29
  # ... as long as original_attrs is not updated.
26
- User._meta.original_attrs["constraints"] = User.Meta.constraints
30
+ # User._meta.original_attrs["constraints"] = User.Meta.constraints
@@ -1,5 +1,4 @@
1
1
  from django.db import migrations, models
2
- from django.db.models.functions import Lower
3
2
 
4
3
 
5
4
  # Copyright (c) 2023 Carlton Gibson
@@ -36,8 +35,8 @@ class Migration(migrations.Migration):
36
35
  CustomAddConstraint(
37
36
  model_name="user",
38
37
  constraint=models.UniqueConstraint(
39
- Lower("email"),
40
- name="unique_user_email"
38
+ fields=["email"],
39
+ name="unique_user_email",
41
40
  ),
42
41
  ),
43
42
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: django-solomon
3
- Version: 0.4.1
3
+ Version: 0.4.3
4
4
  Summary: A Django app for passwordless authentication using magic links.
5
5
  Project-URL: Home, https://django-solomon.rtfd.io/
6
6
  Project-URL: Documentation, https://django-solomon.rtfd.io/
@@ -72,7 +72,8 @@ A Django app for passwordless authentication using magic links.
72
72
  - Privacy-focused IP anonymization
73
73
  - Customizable templates for emails and pages
74
74
  - Compatible with Django's authentication system
75
- - Enforces unique email addresses for users (case-insensitive)
75
+ - Enforces unique email addresses for users (Code is taken
76
+ from [django-unique-user-email](https://github.com/carltongibson/django-unique-user-email). Thanks!)
76
77
 
77
78
  ## Installation
78
79
 
@@ -1,6 +1,6 @@
1
1
  django_solomon/__init__.py,sha256=4GdjeQVyChzdc7pZ1jrpknjcnu9Do_0nSh42UZNICKo,80
2
2
  django_solomon/admin.py,sha256=hwesCOQgUDDHPh5qq97AObfSyMgIOKsdzoa69naMPx4,1428
3
- django_solomon/apps.py,sha256=lmhPt8Cgdk-tr-cK45Ysdkqe8rPrTBH_UqYClpKZ94o,883
3
+ django_solomon/apps.py,sha256=hfkXVS1kp1kAWtl5q2CPkxhP5rxnGq09JvQrYTNj2PA,1114
4
4
  django_solomon/backends.py,sha256=3RN4dsCehg5urp9sfASERFda1VR9nislNvHrxUc7rXM,3171
5
5
  django_solomon/config.py,sha256=JEl3cY0BnfC9ja0ZVeLmfIwUStbUAO6vRhGZrrig5Yw,787
6
6
  django_solomon/forms.py,sha256=ymDsZ-KWyJfo12vGbZCxIhIvVket93xYR4MgDif4fh0,312
@@ -15,14 +15,14 @@ django_solomon/management/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJW
15
15
  django_solomon/management/commands/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
16
16
  django_solomon/migrations/0001_initial.py,sha256=i-UhR1KQ4p7WmbDg9xUQfMmDo8yYdIigvHNsefLHJEc,1981
17
17
  django_solomon/migrations/0002_magiclink_ip_address.py,sha256=hs3MISYV7IHEqF-vELCmFtzhhvK8GEHkZu8RMc4X1YU,432
18
- django_solomon/migrations/0003_add_unique_constraint_auth_user_email.py,sha256=9-etXYGGm72G5bmeSdQNpxfQsVl2fTPLyt2sP-CK0G0,1529
18
+ django_solomon/migrations/0003_add_unique_constraint_auth_user_email.py,sha256=2eZm-oSTtf9zmEy4fJYE6fjMAsn_VUS_zKfW3WQNGoQ,1487
19
19
  django_solomon/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
20
20
  django_solomon/templates/django_solomon/base/invalid_magic_link.html,sha256=3U4T2n4uvPvktiOOHYVyNmk0aXFfE4DPrURE1DinWKk,554
21
21
  django_solomon/templates/django_solomon/base/login_form.html,sha256=VYGnrno3c36W9f04XdRqJpjsDfOy0sq5D_cLayPz8Q0,546
22
22
  django_solomon/templates/django_solomon/base/magic_link_sent.html,sha256=GIMxnw3E98TXVkVQkMRTHmX5mz0xUsvgXVj25gO2HPQ,461
23
23
  django_solomon/templates/django_solomon/email/magic_link.mjml,sha256=OnfVGm2yFrOmoQ1syo6-Duq_Qraf3Tv0Vy5oidvt55g,1427
24
24
  django_solomon/templates/django_solomon/email/magic_link.txt,sha256=yl01eie3U2HkFEJvB1Qlm8Z6FPuop5yubDXFY5V507Q,502
25
- django_solomon-0.4.1.dist-info/METADATA,sha256=a0NZFRUcRHdLooXHNdgye55MofE_8zbcLHkkJC_l5vk,10409
26
- django_solomon-0.4.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
27
- django_solomon-0.4.1.dist-info/licenses/LICENSE,sha256=tbfFOFdH5mHIfmNGo6KGOC3U8f-hTCLfetcr8A89WwI,1071
28
- django_solomon-0.4.1.dist-info/RECORD,,
25
+ django_solomon-0.4.3.dist-info/METADATA,sha256=RFZs39oVqVqI_Hc8LlX25fQC7shz7qdvZsMiPAp6MCs,10508
26
+ django_solomon-0.4.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
27
+ django_solomon-0.4.3.dist-info/licenses/LICENSE,sha256=tbfFOFdH5mHIfmNGo6KGOC3U8f-hTCLfetcr8A89WwI,1071
28
+ django_solomon-0.4.3.dist-info/RECORD,,