diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-10-22 19:38:47 +0200 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-10-22 19:39:44 +0200 |
commit | a9e40a3d80435431f689b8d19005dd77a8f50224 (patch) | |
tree | 48573a1f1ec9c14789c529de3b8fb8badfb20444 /lib/tasks | |
parent | 17122df80dc7e85910a9cfa049d2e33ef84288c6 (diff) |
Adding OAuth access scopes, fixing OAuth authorization UI, adding rate limiting
to the API
Diffstat (limited to 'lib/tasks')
-rw-r--r-- | lib/tasks/mastodon.rake | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/tasks/mastodon.rake b/lib/tasks/mastodon.rake index 78def7b51..94da0904c 100644 --- a/lib/tasks/mastodon.rake +++ b/lib/tasks/mastodon.rake @@ -2,9 +2,7 @@ namespace :mastodon do namespace :media do desc 'Removes media attachments that have not been assigned to any status for longer than a day' task clear: :environment do - MediaAttachment.where(status_id: nil).where('created_at < ?', 1.day.ago).find_each do |m| - m.destroy - end + MediaAttachment.where(status_id: nil).where('created_at < ?', 1.day.ago).find_each(&:destroy) end end |