isomorfeus-puppetmaster 0.6.3 → 0.6.4

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
  SHA256:
3
- metadata.gz: 4b331458dc7edd860f8c85ee68ba81ef4a7b18e43de0db41f3e8b5246cfd6f78
4
- data.tar.gz: 250af210fc9adca4077cbe57ffb5490e5e8f0a0b74b018513db3bd81c2254763
3
+ metadata.gz: e54d9dd005c6c0e9afa0f9a18ea7a0a6a837da33b0eb5ec53faf81a7ce3056d2
4
+ data.tar.gz: 6f783f0d1e7fe33f94ea023441e3cef2b2a556b9424b5b39e09c29a319102b0e
5
5
  SHA512:
6
- metadata.gz: 638061fd42b4a70c18db00543eb70c1f830165b3b059ea14cda1d9b5d9cadfee69f5ff2365ba5b87f317646701d76ddc645333a5068801841bee725ce89b0d49
7
- data.tar.gz: 64835b4b1e4a5c88e0457bc1338007f55bd8ff806c24d1596b15a6e1f206833af7331dfe1b0a233d9fbc793c6848a09f645e1b3b49a3bc8213e1b237e9727bf4
6
+ metadata.gz: 529c766594a02a539251eb416b360c05d0dd0b490a64974b44bf0c06d2983c01dc2bdf32a0e6fc69f4815b2a44fae3ebdd7d27da1f86ff191685d2c609319572
7
+ data.tar.gz: 6e5ccce74a50c1435f99ecc1f3e80e0c28b3e4df98f17261d274211fddc61b4e01d34cbcddb8a403905a612d38ee3cc0f4286b74fb9534deab9bb59ef00e9801
@@ -1,3 +1,3 @@
1
1
  module Isomorfeus
2
- PUPPETMASTER_VERSION = '0.6.3'
2
+ PUPPETMASTER_VERSION = '0.6.4'
3
3
  end
@@ -9,8 +9,11 @@ module Isomorfeus
9
9
  end
10
10
 
11
11
  def block_source_code(&block)
12
- source_block = Parser::CurrentRuby.parse(block.source).children.last
13
- source_block = source_block.children.last if source_block.type == :block
12
+ source_block = Parser::CurrentRuby.parse(block.source.strip)
13
+ unless source_block.type == :block
14
+ source_block = source_block.children[source_block.children.index { |c| c.respond_to?(:type) && c.type == :block }]
15
+ end
16
+ source_block = source_block.children[2]
14
17
  Unparser.unparse(source_block)
15
18
  end
16
19
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: isomorfeus-puppetmaster
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.3
4
+ version: 0.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Biedermann