Skip to content

Commit

Permalink
Fix wrong use of collect method
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Jun 27, 2014
1 parent d7b97e0 commit b6d6db7
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/droonga/dispatcher.rb
Original file line number Diff line number Diff line change
Expand Up @@ -187,15 +187,19 @@ def dispatch_steps(steps)
one_way_step.delete("post")
one_way_step.delete("outputs")
one_way_steps << one_way_step
one_way_destinations += routes.collect(&:farm_path)
one_way_destinations += routes.collect do |route|
farm_path(route)
end
end
end
routes = dataset.get_routes(step, @engine_state.live_nodes)
step["routes"] = routes
else
step["routes"] ||= [id]
end
destinations += step["routes"].collect(&:farm_path)
destinations += step["routes"].collect do |route|
farm_path(route)
end
end

dispatch_message = { "id" => id, "steps" => steps }
Expand Down

0 comments on commit b6d6db7

Please sign in to comment.