backports 3.0.1 → 3.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,9 +3,7 @@ class Hash
3
3
  self
4
4
  end unless method_defined? :to_h
5
5
 
6
- begin
7
- {}.default_proc = nil
8
- rescue
6
+ if (({}.default_proc = nil) rescue true)
9
7
  def default_proc_with_nil=(proc)
10
8
  if proc == nil
11
9
  self.default = nil
@@ -14,6 +12,7 @@ class Hash
14
12
  self.default_proc_without_nil=(proc)
15
13
  end
16
14
  end
15
+ Backports.alias_method_chain(self, :default_proc=, :nil)
17
16
  end
18
17
  end
19
18
 
@@ -1,3 +1,3 @@
1
1
  module Backports
2
- VERSION = "3.0.1"
2
+ VERSION = "3.0.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: backports
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1
4
+ version: 3.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: