diff --git a/config/initializers/rack_attack.rb b/config/initializers/rack_attack.rb index 3fb22c6321..456c575cb3 100644 --- a/config/initializers/rack_attack.rb +++ b/config/initializers/rack_attack.rb @@ -77,7 +77,7 @@ class Rack::Attack API_DELETE_REBLOG_REGEX = /\A\/api\/v1\/statuses\/[\d]+\/unreblog/.freeze API_DELETE_STATUS_REGEX = /\A\/api\/v1\/statuses\/[\d]+/.freeze - throttle('throttle_api_delete', limit: 30, period: 5.minutes) do |req| + throttle('throttle_api_delete', limit: 60, period: 5.minutes) do |req| req.authenticated_user_id if (req.post? && req.path.match?(API_DELETE_REBLOG_REGEX)) || (req.delete? && req.path.match?(API_DELETE_STATUS_REGEX)) end