hydra 0.16.3 → 0.16.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/VERSION +1 -1
  2. data/hydra.gemspec +1 -1
  3. data/lib/hydra/safe_fork.rb +2 -2
  4. metadata +2 -2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.16.3
1
+ 0.16.4
data/hydra.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{hydra}
8
- s.version = "0.16.3"
8
+ s.version = "0.16.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Nick Gauthier"]
@@ -8,7 +8,7 @@ class SafeFork
8
8
  begin
9
9
  # create a new connection and perform the action
10
10
  begin
11
- ActiveRecord::Base.establish_connection(connection.merge({:allow_concurrency => true})) if defined?(ActiveRecord)
11
+ ActiveRecord::Base.establish_connection((connection || {}).merge({:allow_concurrency => true})) if defined?(ActiveRecord)
12
12
  rescue ActiveRecord::AdapterNotSpecified
13
13
  # AR was defined but we didn't have a connection
14
14
  end
@@ -21,7 +21,7 @@ class SafeFork
21
21
  ensure
22
22
  # make sure we re-establish the connection before returning to the main instance
23
23
  begin
24
- ActiveRecord::Base.establish_connection(connection.merge({:allow_concurrency => true})) if defined?(ActiveRecord)
24
+ ActiveRecord::Base.establish_connection((connection || {}).merge({:allow_concurrency => true})) if defined?(ActiveRecord)
25
25
  rescue ActiveRecord::AdapterNotSpecified
26
26
  # AR was defined but we didn't have a connection
27
27
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 16
8
- - 3
9
- version: 0.16.3
8
+ - 4
9
+ version: 0.16.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - Nick Gauthier