creeper 1.0.4 → 1.0.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -98,10 +98,10 @@ module Creeper
98
98
 
99
99
  ## daemon ##
100
100
 
101
- def work(jobs = nil, size = 2)
101
+ def work(jobs = nil, size = nil)
102
102
  require 'creeper/worker'
103
103
 
104
- Creeper.pool_size = size
104
+ Creeper.pool_size = size || Creeper.pool_size
105
105
 
106
106
  Creeper::Worker.work(jobs, Creeper.pool_size)
107
107
  end
@@ -1,3 +1,3 @@
1
1
  module Creeper
2
- VERSION = "1.0.4"
2
+ VERSION = "1.0.5"
3
3
  end
@@ -12,7 +12,9 @@ module Creeper
12
12
 
13
13
  class Worker
14
14
 
15
- def self.work(jobs = nil, size = 2)
15
+ def self.work(jobs = nil, size = nil)
16
+
17
+ size ||= Creeper.pool_size
16
18
 
17
19
  options = {
18
20
  size: size,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: creeper
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: