Skip to content

Commit a6616c0

Browse files
committed
Fix store name in admin interface
1 parent dbfa5c5 commit a6616c0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

fileshack/models.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ class Store(Model):
4242
allow_watch = BooleanField(_("allow watch"), help_text=_('Allow users to subscribe to receive e-mail updates. Requires cron (see <a href="http://fileshack.sourceforge.net/doc/#store-watching">documentation</a>).'), default=False)
4343
watch_delay = PositiveIntegerField(_("watch delay"), help_text=_("Minimum delay between two notifications in minutes. Only applies when <strong>Allow watch</strong> is enabled."), default=360)
4444

45-
def __unicode__(self):
46-
url = self.get_absolute_url()
45+
def __str__(self):
46+
url = urllib.parse.unquote(self.get_absolute_url())
4747
if url.startswith("/"):
4848
url = url[1:]
4949
return "default" if url == "" else url
@@ -138,7 +138,7 @@ def simple(self):
138138
"uploaded": self.uploaded,
139139
}
140140

141-
def __unicode__(self):
141+
def __str__(self):
142142
return self.name()
143143

144144
class Meta:

0 commit comments

Comments
 (0)