Dashes for underscore users

master
Nick Sergeant 2012-06-07 10:22:03 -04:00
parent 605d2a237f
commit e8d29139ec
1 changed files with 1 additions and 1 deletions

View File

@ -100,7 +100,7 @@ class Snipt(models.Model):
if self.user.id == 3:
return 'http://nicksergeant.com/{}/'.format(self.slug)
else:
return 'https://{}.snipt.net/{}/'.format(self.user.username, self.slug)
return 'https://{}.snipt.net/{}/'.format(self.user.username.replace('_', '-'), self.slug)
if self.custom_slug:
return '/{}/'.format(self.custom_slug)