Skip to content

Commit

Permalink
✨ make token unique
Browse files Browse the repository at this point in the history
  • Loading branch information
annashamray committed May 2, 2024
1 parent d6cc394 commit af38c8a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ class Migration(migrations.Migration):
migrations.AlterField(
model_name="tokenauth",
name="token",
field=models.CharField(db_index=True, max_length=40, verbose_name="token"),
field=models.CharField(max_length=40, unique=True, verbose_name="token"),
),
]
2 changes: 1 addition & 1 deletion src/objects/token/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


class TokenAuth(models.Model):
token = models.CharField(_("token"), max_length=40, db_index=True)
token = models.CharField(_("token"), max_length=40, unique=True)
contact_person = models.CharField(
_("contact person"),
max_length=200,
Expand Down

0 comments on commit af38c8a

Please sign in to comment.