2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-08-21 19:11:18 +08:00

factor out @post.revise into its own class. clean up PostRevisor class to be more readable

This commit is contained in:
Grant Ammons 2013-02-09 10:33:07 -05:00
parent f44dba5fc5
commit 701ecddac2
5 changed files with 263 additions and 74 deletions

6
lib/edit_rate_limiter.rb Normal file
View file

@ -0,0 +1,6 @@
require 'rate_limiter'
class EditRateLimiter < RateLimiter
def initialize(user)
super(user, "edit-post:#{Date.today.to_s}", SiteSetting.max_edits_per_day, 1.day.to_i)
end
end