mirror of
https://github.com/kikobar/mastodon.git
synced 2024-11-18 13:17:35 +00:00
Fix tootctl domains crawl
with JSON format output crash (#9820)
Fix #9817
This commit is contained in:
parent
a4f07bad95
commit
59e3a7f87b
|
@ -140,15 +140,8 @@ module Mastodon
|
||||||
end
|
end
|
||||||
|
|
||||||
def stats_to_json(stats)
|
def stats_to_json(stats)
|
||||||
totals.each_key do |domain|
|
stats.compact!
|
||||||
if totals[domain].is_a?(Hash)
|
say(Oj.dump(stats))
|
||||||
totals[domain]['activity'] = stats[domain]
|
|
||||||
else
|
|
||||||
totals.delete(domain)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
say(Oj.dump(totals))
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue