We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
random_id
1 parent 770ef72 commit f1c8109Copy full SHA for f1c8109
frameworks/Ruby/rails/app/controllers/hello_world_controller.rb
@@ -33,8 +33,8 @@ def fortune
33
end
34
35
def update
36
- worlds = Array.new(query_count) do
37
- world = World.find(random_id)
+ worlds = ALL_IDS.sample(query_count).map do |id|
+ world = World.find(id)
38
new_value = random_id
39
new_value = random_id until new_value != world.randomNumber
40
world.update_columns(randomNumber: new_value)
0 commit comments