Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #2139 -- Changed Redirect repr to str

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3122 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 15437d7a8847e459ceca4d607667e16ef796dfb0 1 parent 4fcb72d
Adrian Holovaty authored June 12, 2006

Showing 1 changed file with 3 additions and 1 deletion. Show diff stats Hide diff stats

  1. 4  django/contrib/redirects/models.py
4  django/contrib/redirects/models.py
@@ -8,15 +8,17 @@ class Redirect(models.Model):
8 8
         help_text=_("This should be an absolute path, excluding the domain name. Example: '/events/search/'."))
9 9
     new_path = models.CharField(_('redirect to'), maxlength=200, blank=True,
10 10
         help_text=_("This can be either an absolute path (as above) or a full URL starting with 'http://'."))
  11
+
11 12
     class Meta:
12 13
         verbose_name = _('redirect')
13 14
         verbose_name_plural = _('redirects')
14 15
         db_table = 'django_redirect'
15 16
         unique_together=(('site', 'old_path'),)
16 17
         ordering = ('old_path',)
  18
+
17 19
     class Admin:
18 20
         list_filter = ('site',)
19 21
         search_fields = ('old_path', 'new_path')
20 22
 
21  
-    def __repr__(self):
  23
+    def __str__(self):
22 24
         return "%s ---> %s" % (self.old_path, self.new_path)

0 notes on commit 15437d7

Please sign in to comment.
Something went wrong with that request. Please try again.