summaryrefslogtreecommitdiff
path: root/mirrors/models.py
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2012-04-26 11:53:49 -0500
committerDan McGee <dan@archlinux.org>2012-04-26 11:53:49 -0500
commit7f2ed459e92b56c28a8ca50292e95a42987544d4 (patch)
tree36b31d66078b803dd1a6ef071fafc27ec9d2fe9a /mirrors/models.py
parent4dcfaddff526dca2828571326aa7263a3272fcdf (diff)
Remove now-unused NullCharField
It would be straightforward if we just needed to remove the field class definition, but we also need to update all migrations that referenced it so we don't have problems starting and migrating from scratch. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'mirrors/models.py')
-rw-r--r--mirrors/models.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/mirrors/models.py b/mirrors/models.py
index c23622fa..19437610 100644
--- a/mirrors/models.py
+++ b/mirrors/models.py
@@ -5,14 +5,6 @@ from django.db import models
from django.core.exceptions import ValidationError
from django_countries import CountryField
-class NullCharField(models.CharField):
- description = "String (up to %(max_length)s), NULL if value is empty"
- _south_introspects = True
-
- def get_prep_value(self, value):
- if value == '':
- return None
- return self.to_python(value)
TIER_CHOICES = (
(0, 'Tier 0'),
@@ -21,6 +13,7 @@ TIER_CHOICES = (
(-1, 'Untiered'),
)
+
class Mirror(models.Model):
name = models.CharField(max_length=255, unique=True)
tier = models.SmallIntegerField(default=2, choices=TIER_CHOICES)