summaryrefslogtreecommitdiff
path: root/lib/chef/chef_fs/parallelizer
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2016-08-09 12:31:44 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2016-08-16 18:41:25 -0700
commit7037433634d0b02574d03a8465541ea2f49d3f39 (patch)
treebb708bd38fbb6f86d0f0f01eb0b9a2da03423fd7 /lib/chef/chef_fs/parallelizer
parent498d60207ce6664f0ca807b3f7a4690b3097014c (diff)
downloadchef-7037433634d0b02574d03a8465541ea2f49d3f39.tar.gz
autofixing Style/WhileUntilModifier cop
Diffstat (limited to 'lib/chef/chef_fs/parallelizer')
-rw-r--r--lib/chef/chef_fs/parallelizer/parallel_enumerable.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/chef/chef_fs/parallelizer/parallel_enumerable.rb b/lib/chef/chef_fs/parallelizer/parallel_enumerable.rb
index 9d02bbab78..ab578bdb7f 100644
--- a/lib/chef/chef_fs/parallelizer/parallel_enumerable.rb
+++ b/lib/chef/chef_fs/parallelizer/parallel_enumerable.rb
@@ -184,9 +184,7 @@ class Chef
sleep(0.01)
end
- until @unconsumed_output.empty?
- yield @unconsumed_output.pop
- end
+ yield @unconsumed_output.pop until @unconsumed_output.empty?
# If no one is working on our tasks and we're allowed to
# work on them in the main thread, process an input to
@@ -227,9 +225,7 @@ class Chef
def stop
@unconsumed_input.clear
- while @in_process.size > 0
- sleep(0.05)
- end
+ sleep(0.05) while @in_process.size > 0
@unconsumed_output.clear
end