subscription channels required
All checks were successful
Build and Push Docker Image / build (push) Successful in 8s
All checks were successful
Build and Push Docker Image / build (push) Successful in 8s
set blank=False, meaning 400 error will be raised if the channels field is missing or blank.
This commit is contained in:
parent
19c1657813
commit
c5595ab823
18
apps/home/migrations/0013_alter_subscription_channels.py
Normal file
18
apps/home/migrations/0013_alter_subscription_channels.py
Normal file
@ -0,0 +1,18 @@
|
||||
# Generated by Django 5.0.4 on 2024-10-14 22:28
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('home', '0012_alter_server_is_bot_operational'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='subscription',
|
||||
name='channels',
|
||||
field=models.ManyToManyField(related_name='subscriptions', to='home.discordchannel'),
|
||||
),
|
||||
]
|
@ -238,7 +238,7 @@ class Subscription(models.Model):
|
||||
active = models.BooleanField(default=True)
|
||||
|
||||
publish_threshold = models.DateTimeField(default=timezone.now)
|
||||
channels = models.ManyToManyField(to=DiscordChannel, related_name="subscriptions", blank=True)
|
||||
channels = models.ManyToManyField(to=DiscordChannel, related_name="subscriptions", blank=False)
|
||||
filters = models.ManyToManyField(to=ContentFilter, blank=True)
|
||||
message_style = models.ForeignKey(to=MessageStyle, on_delete=models.SET_NULL, null=True, blank=True)
|
||||
unique_rules = models.ManyToManyField(to=UniqueContentRule, blank=False)
|
||||
|
Loading…
x
Reference in New Issue
Block a user