libis-tools 0.9.5 → 0.9.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 29a2f53e5ac6fb5e2432eddac4617092644fc545
4
- data.tar.gz: 8576f7fb158f2e8cde213edbe2cbf9d0444ac6fd
3
+ metadata.gz: abe45e9ce73f0da4087c1cbfe554a9d8d62680c9
4
+ data.tar.gz: 845d2bbee0b78df26160501a4a15bb532ac62e1a
5
5
  SHA512:
6
- metadata.gz: ebbd5da879c6a915be6659b699fbdb5e751c932c11b7f4bf85451f5ced8f612d02f191a6976468a5d55e521323035b408e28e7942d9224232cdf9207b081120b
7
- data.tar.gz: 2275268123728cfaf39fa811cdf09a1e154855f5bafcb083c9aefa49f335a5230283a831da39e02a73bb16d85dcbf01dbbf975670bab4e584935e5348fb955e7
6
+ metadata.gz: afa5e9bfd7b2ea4c908046159b718e70868fa3160559f5ebe350c5e81bf7d601dae1f7aa168cea4f914249e561fbdb627e3d67a9db19ce4b3e3fbd6e104ab4a0
7
+ data.tar.gz: d1f52ac47989cc3bfe353d14b15ef581c3121826a06fb1c9e240364c03a291a5ec64c66da656c9bc1c4de0825f2593f92053cdac6bdee58e7e565a75bb8c18ca
@@ -102,8 +102,8 @@ module Libis
102
102
 
103
103
  protected
104
104
 
105
- def initialize
106
- super
105
+ def initialize(hash = nil, opts = {})
106
+ super(hash, opts)
107
107
  clear!
108
108
  end
109
109
 
@@ -33,8 +33,8 @@ module Libis
33
33
  # passed to the {#<<} method after initialization.
34
34
  #
35
35
  # @param [String,Hash] file_or_hash optional String or Hash argument to initialize the data.
36
- def initialize(file_or_hash = nil)
37
- super
36
+ def initialize(file_or_hash = nil, opt = {})
37
+ super({}, opt)
38
38
  self << file_or_hash
39
39
  end
40
40
 
@@ -48,7 +48,7 @@ module Libis
48
48
  #
49
49
  # @param [String,Hash] file_or_hash optional String or Hash argument to initialize the data.
50
50
  def <<(file_or_hash)
51
- return self if file_or_hash.nil?
51
+ return self if file_or_hash.nil? || (file_or_hash.respond_to?(:empty?) && file_or_hash.empty?)
52
52
  hash = case file_or_hash
53
53
  when Hash
54
54
  yield file_or_hash if block_given?
@@ -1,5 +1,5 @@
1
1
  module Libis
2
2
  module Tools
3
- VERSION = '0.9.5'
3
+ VERSION = '0.9.6'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: libis-tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.5
4
+ version: 0.9.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kris Dekeyser