Don't count failed attempts against community creation limit
Patch by wyntarvox.
diffs (25 lines):
diff -r e352f4cd3bdb -r 95b235f654e5 htdocs/community/create.bml
--- a/htdocs/community/create.bml Sat May 16 12:34:55 2009 +0000
+++ b/htdocs/community/create.bml Sat May 16 13:12:11 2009 +0000
@@ -45,10 +45,6 @@ SUBMIT:
# Note: If a captcha check is added, then form auth would be redundant
return "<b>$ML{'Error'}</b>: $ML{'error.invalidform'}" unless
LJ::check_form_auth();
- # rate limit
- return "<b>$ML{'Error'}</b>: $ML{'.error.ratelimited'}"
- unless $remote->rate_log( 'commcreate', 1 );
-
my $user = LJ::canonical_username($POST{user});
my $title = $POST{title} || $user;
@@ -79,6 +75,10 @@ SUBMIT:
}
last SUBMIT if $error;
+
+ # rate limit
+ return "<b>$ML{'Error'}</b>: $ML{'.error.ratelimited'}"
+ unless $remote->rate_log( 'commcreate', 1 );
unless ($second_submit) {
$u = LJ::User->create_community(
_______________________________________________
dw-changelog mailing list
[email protected]
http://lists.dwscoalition.org/mailman/listinfo/dw-changelog