Mercurial > public > sg101
annotate gpp/antispam/__init__.py @ 492:3c48a555298d
Added a custom tag to display a link to a profile. Refactored the avatar tag to optionally display a profile link around the image. Removed the width and height attributes from the avatar image tag. I think this was causing disk hits whenever those properties were not cached. The avatar tag is now an inclusion tag.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 22 Oct 2011 00:07:50 +0000 |
parents | 7c3816d76c6c |
children | 2c2df8545112 |
rev | line source |
---|---|
bgneal@472 | 1 from django.contrib.auth import views as auth_views |
bgneal@472 | 2 |
bgneal@472 | 3 from antispam.decorators import rate_limit |
bgneal@472 | 4 |
bgneal@214 | 5 SPAM_PHRASE_KEY = "antispam.spam_phrases" |
bgneal@215 | 6 BUSTED_MESSAGE = ("Your post has tripped our spam filter. Your account has " |
bgneal@215 | 7 "been suspended pending a review of your post. If this was a mistake " |
bgneal@215 | 8 "then we apologize; your account will be restored shortly.") |
bgneal@472 | 9 |
bgneal@472 | 10 # Install rate limiting on auth login |
bgneal@472 | 11 auth_views.login = rate_limit()(auth_views.login) |