fix migration creating conflicting tags based on slug
This commit is contained in:
parent
4d21a04ab5
commit
aa84a7ff2b
1 changed files with 1 additions and 1 deletions
|
@ -17,7 +17,7 @@ def forwards_func(apps, schema_editor):
|
|||
tag_set.discard("")
|
||||
|
||||
for tag in tag_set:
|
||||
to_add, _ = TagModel.objects.get_or_create(name=tag, slug=slugify(tag))
|
||||
to_add, _ = TagModel.objects.get_or_create(name=tag, defaults={'slug': slugify(tag)})
|
||||
snapshot.tags.add(to_add)
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue