aboutsummaryrefslogtreecommitdiffstats
path: root/pydis_site
diff options
context:
space:
mode:
authorGravatar Matteo Bertucci <[email protected]>2019-10-31 13:16:15 +0100
committerGravatar Matteo Bertucci <[email protected]>2019-10-31 13:16:15 +0100
commit904edb20f694c40435ba27f5a96f759dbf87f3e3 (patch)
treef6b71ea47b8f049a65ce95be66b99692b4b8e90a /pydis_site
parentMerge branch 'master' into bot#549-show-attachments-staff (diff)
Allow empty attachment field
Diffstat (limited to 'pydis_site')
-rw-r--r--pydis_site/apps/api/migrations/0048_alter_deletedmessage_api.py19
-rw-r--r--pydis_site/apps/api/models/bot/message.py1
2 files changed, 20 insertions, 0 deletions
diff --git a/pydis_site/apps/api/migrations/0048_alter_deletedmessage_api.py b/pydis_site/apps/api/migrations/0048_alter_deletedmessage_api.py
new file mode 100644
index 00000000..364f57b1
--- /dev/null
+++ b/pydis_site/apps/api/migrations/0048_alter_deletedmessage_api.py
@@ -0,0 +1,19 @@
+# Generated by Django 2.2.6 on 2019-10-31 12:14
+
+import django.contrib.postgres.fields
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('api', '0047_deletedmessage_attachments'),
+ ]
+
+ operations = [
+ migrations.AlterField(
+ model_name='deletedmessage',
+ name='attachments',
+ field=django.contrib.postgres.fields.ArrayField(base_field=models.URLField(max_length=512), blank=True, help_text='Attachments attached to this message.', size=None),
+ ),
+ ]
diff --git a/pydis_site/apps/api/models/bot/message.py b/pydis_site/apps/api/models/bot/message.py
index 72b0b61a..8b18fc9f 100644
--- a/pydis_site/apps/api/models/bot/message.py
+++ b/pydis_site/apps/api/models/bot/message.py
@@ -55,6 +55,7 @@ class Message(ModelReprMixin, models.Model):
models.URLField(
max_length=512
),
+ blank=True,
help_text="Attachments attached to this message."
)