diff --git a/openwisp_radius/migrations/0035_organizationradiussettings_sms_cooldown.py b/openwisp_radius/migrations/0035_organizationradiussettings_sms_cooldown.py index 03b4b6bc..d0880276 100644 --- a/openwisp_radius/migrations/0035_organizationradiussettings_sms_cooldown.py +++ b/openwisp_radius/migrations/0035_organizationradiussettings_sms_cooldown.py @@ -4,6 +4,8 @@ import openwisp_utils.fields +from .. import settings as app_settings + class Migration(migrations.Migration): dependencies = [ @@ -16,7 +18,7 @@ class Migration(migrations.Migration): name="sms_cooldown", field=openwisp_utils.fields.FallbackPositiveIntegerField( blank=True, - fallback=30, + fallback=app_settings.SMS_COOLDOWN, help_text=( "Time period a user will have to wait before" " requesting another SMS token (in seconds)." diff --git a/openwisp_radius/migrations/0037_alter_organizationradiussettings_allowed_mobile_prefixes_and_more.py b/openwisp_radius/migrations/0037_alter_organizationradiussettings_allowed_mobile_prefixes_and_more.py index cab2d8ea..e68cf6d9 100644 --- a/openwisp_radius/migrations/0037_alter_organizationradiussettings_allowed_mobile_prefixes_and_more.py +++ b/openwisp_radius/migrations/0037_alter_organizationradiussettings_allowed_mobile_prefixes_and_more.py @@ -1,4 +1,4 @@ -# Generated by Django 4.2.11 on 2024-07-17 11:02 +# Generated by Django 4.2.14 on 2024-08-07 16:38 from django.db import migrations @@ -58,19 +58,4 @@ class Migration(migrations.Migration): verbose_name="Password reset URL", ), ), - migrations.AlterField( - model_name="organizationradiussettings", - name="sms_cooldown", - field=openwisp_utils.fields.FallbackPositiveIntegerField( - blank=True, - default=None, - fallback=app_settings.SMS_COOLDOWN, - help_text=( - "Time period a user will have to wait before requesting" - " another SMS token (in seconds)." - ), - null=True, - verbose_name="SMS Cooldown", - ), - ), ] diff --git a/openwisp_radius/tests/test_admin.py b/openwisp_radius/tests/test_admin.py index 461e158c..c76a55f0 100644 --- a/openwisp_radius/tests/test_admin.py +++ b/openwisp_radius/tests/test_admin.py @@ -674,7 +674,7 @@ def test_backward_compatible_default_password_reset_url(self): # The default value is set on project startup, hence # it also requires mocking. OrganizationRadiusSettings._meta.get_field('password_reset_url'), - 'default', + 'fallback', app_settings.DEFAULT_PASSWORD_RESET_URL, ): response = self.client.get(url)