Make the username unique.

This commit is contained in:
2011-06-15 09:01:52 +01:00
parent 0f6ef34d26
commit ac69b7450a
2 changed files with 73 additions and 1 deletions

View File

@@ -22,7 +22,7 @@ class RedditAccount(models.Model):
user = models.ForeignKey(User, blank=True, null=True)
username = models.CharField("Reddit Username", max_length=32, blank=False)
username = models.CharField("Reddit Username", max_length=32, blank=False, unique=True)
reddit_id = models.CharField("Reddit ID", max_length=32)
link_karma = models.IntegerField("Link Karma")