Skip to content

Commit b16b24c

Browse files
committed
Adapted initial migration to not cause new migration with Django 4
1 parent 4da9d1f commit b16b24c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

django_comments/migrations/0001_initial.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ class Migration(migrations.Migration):
3030
help_text='Check this box if the comment is inappropriate. A "This comment has been removed"'
3131
' message will be displayed instead.',
3232
verbose_name='is removed')),
33-
('content_type', models.ForeignKey(related_name='content_type_set_for_comment',
33+
('content_type', models.ForeignKey(related_name='content_type_set_for_%(class)s',
3434
verbose_name='content type', to='contenttypes.ContentType',
3535
on_delete=models.CASCADE)),
3636
('site', models.ForeignKey(to='sites.Site', on_delete=models.CASCADE)),
37-
('user', models.ForeignKey(related_name='comment_comments', verbose_name='user',
37+
('user', models.ForeignKey(related_name='%(class)s_comments', verbose_name='user',
3838
blank=True, to=settings.AUTH_USER_MODEL, null=True, on_delete=models.SET_NULL)),
3939
],
4040
options={

0 commit comments

Comments
 (0)