discourse/discourse — pull request #1732 by chancancode (2013-12-12 10:23:11+00:00)
Title: Stop using `return` in inline callbacks

In Rails 4.1, using `return` statements inside these inline callbacks will not be supported anymore. See rails/rails#13271 for all the details.

* I haven't looked into what the callbacks are actually doing in `topics.rb`, so I went with the most generic names.
* In rate limiter, I used the lambda trick to avoid defining dynamic methods (see the same rails ticket for details)

Open to suggestions on how best to transition these.