Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
migrations: Fix initial value for automatic policy migrations.
Tim Abbott2bfbbf0035a0
diff --git a/zerver/migrations/0476_realmuserdefault_automatically_follow_topics_policy_and_more.py b/zerver/migrations/0476_realmuserdefault_automatically_follow_topics_policy_and_more.pyindex 7dc6406bc51..4f8952fef05 100644--- a/zerver/migrations/0476_realmuserdefault_automatically_follow_topics_policy_and_more.py+++ b/zerver/migrations/0476_realmuserdefault_automatically_follow_topics_policy_and_more.py@@ -2,6 +2,8 @@from django.db import migrations, models+AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER = 4+class Migration(migrations.Migration):dependencies = [@@ -12,21 +14,29 @@ class Migration(migrations.Migration):migrations.AddField(model_name="realmuserdefault",name="automatically_follow_topics_policy",- field=models.PositiveSmallIntegerField(default=3),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AddField(model_name="realmuserdefault",name="automatically_unmute_topics_in_muted_streams_policy",- field=models.PositiveSmallIntegerField(default=3),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AddField(model_name="userprofile",name="automatically_follow_topics_policy",- field=models.PositiveSmallIntegerField(default=3),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AddField(model_name="userprofile",name="automatically_unmute_topics_in_muted_streams_policy",- field=models.PositiveSmallIntegerField(default=3),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),]diff --git a/zerver/migrations/0477_alter_realmuserdefault_automatically_follow_topics_policy_and_more.py b/zerver/migrations/0477_alter_realmuserdefault_automatically_follow_topics_policy_and_more.pyindex da37d33174e..7ad1fbe5f72 100644--- a/zerver/migrations/0477_alter_realmuserdefault_automatically_follow_topics_policy_and_more.py+++ b/zerver/migrations/0477_alter_realmuserdefault_automatically_follow_topics_policy_and_more.py@@ -2,6 +2,8 @@from django.db import migrations, models+AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER = 4+class Migration(migrations.Migration):dependencies = [@@ -12,21 +14,29 @@ class Migration(migrations.Migration):migrations.AlterField(model_name="realmuserdefault",name="automatically_follow_topics_policy",- field=models.PositiveSmallIntegerField(default=4),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AlterField(model_name="realmuserdefault",name="automatically_unmute_topics_in_muted_streams_policy",- field=models.PositiveSmallIntegerField(default=4),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AlterField(model_name="userprofile",name="automatically_follow_topics_policy",- field=models.PositiveSmallIntegerField(default=4),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),migrations.AlterField(model_name="userprofile",name="automatically_unmute_topics_in_muted_streams_policy",- field=models.PositiveSmallIntegerField(default=4),+ field=models.PositiveSmallIntegerField(+ default=AUTOMATICALLY_CHANGE_VISIBILITY_POLICY_NEVER+ ),),]