From c99bc5d51bb588a56c7c8cfcee3a3a5ab3841a95 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Mon, 6 Apr 2020 14:11:47 +0200 Subject: [PATCH] Fix regression in `tootctl media remove-orphans` (#13405) Fix #13401 --- lib/mastodon/media_cli.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/mastodon/media_cli.rb b/lib/mastodon/media_cli.rb index 08a8f109373..0f211f2726a 100644 --- a/lib/mastodon/media_cli.rb +++ b/lib/mastodon/media_cli.rb @@ -276,7 +276,7 @@ module Mastodon preload_map = Hash.new { |hash, key| hash[key] = [] } objects.map do |object| - segments = object.key.split('/').first + segments = object.key.split('/') model_name = segments.first.classify record_id = segments[2..-2].join.to_i