Browse Source

web/postkey/models.py: permit non-unique hashes in database

This needed because hosts.txt already contains a duplicates. But we
shouldn't permit adding dups via webinterface.
pull/1/head
Hidden Z 14 years ago
parent
commit
def26f43ef
  1. 2
      web/postkey/models.py

2
web/postkey/models.py

@ -4,7 +4,7 @@ class i2phost(models.Model):
# Hostname limit is 67 characters maximum, including the '.i2p'. # Hostname limit is 67 characters maximum, including the '.i2p'.
name = models.CharField("I2P hostname", max_length=67, unique=True) name = models.CharField("I2P hostname", max_length=67, unique=True)
# Maximum key length 616 bytes (to account for certs up to 100 bytes). # Maximum key length 616 bytes (to account for certs up to 100 bytes).
b64hash = models.CharField("Base 64 hash", max_length=616, unique=True) b64hash = models.CharField("Base 64 hash", max_length=616)
description = models.TextField("Description", blank=True) description = models.TextField("Description", blank=True)
date_added = models.DateTimeField(auto_now_add=True) date_added = models.DateTimeField(auto_now_add=True)
activated = models.BooleanField(default=False) activated = models.BooleanField(default=False)

Loading…
Cancel
Save