mirror of
https://gitea.invidious.io/iv-org/shard-ameba.git
synced 2024-08-15 00:53:29 +00:00
Use Enumerable#zip
ftw
This commit is contained in:
parent
1399aa3cdf
commit
6a180757f3
1 changed files with 1 additions and 2 deletions
|
@ -88,8 +88,7 @@ module Ameba
|
|||
@formatter.started @sources
|
||||
|
||||
channels = @sources.map { Channel(Exception?).new }
|
||||
@sources.each_with_index do |source, idx|
|
||||
channel = channels[idx]
|
||||
@sources.zip(channels).each do |source, channel|
|
||||
spawn do
|
||||
run_source(source)
|
||||
rescue e
|
||||
|
|
Loading…
Reference in a new issue