csv_decision 0.5.0 → 0.5.1

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: ff2fef716b98e6c7e35b1ff4e6d60adf92747295
4
- data.tar.gz: bc4c0f940707518e82019b7aa0d16f0107ec01d1
3
+ metadata.gz: eb3dff1dad1cc2af4ddb29fd70e6a6c9e0a938de
4
+ data.tar.gz: b0f97ed7f6f0710ae21dfc68d2e2096ffc08ffc6
5
5
  SHA512:
6
- metadata.gz: fb2d0b990168df3597d3131e48fc1ee8c620fe3b886acb23ffa71eabde146d9e2f7425f927ac74c02fc3e3acfbd2f56eae1a46bbeaf2fef614669b9a28dc6e24
7
- data.tar.gz: 2a7beb77db22e035bdb36cb34ad1a96e22078afdd4974e0f7b7ebcda9465d5c04999cb0882b47534b3fc372bb45b76c384df77363cfd71d00ab8a5c11dfbbd87
6
+ metadata.gz: 51f99fa32d541200a4f00f75973a4197fec8c1f6f8578dfc6fcaf6b52eb5017c8f69f72637435ad318f0ce306163ac8b08c402654dd68ce10413ce36e703b06a
7
+ data.tar.gz: b1d4b16f56394974959c629879a299d2fdbf873eef85d3c46e53aa8841f345a091c68a376fef03bae06a0d1c2ee4351d5404f80ff337e48e99cf1809f75dbf31
@@ -1,3 +1,7 @@
1
+ ## v0.5.1, 12 February 2018.
2
+ *Bug Fix*
3
+ - Fix bug when using a path to scan for a first match.
4
+
1
5
  ## v0.5.0, 11 February 2018.
2
6
  *Additions*
3
7
  - Add the ability to specify an input hash path using path: column types.
@@ -5,7 +5,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
 
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = 'csv_decision'
8
- spec.version = '0.5.0'
8
+ spec.version = '0.5.1'
9
9
  spec.authors = ['Brett Vickers']
10
10
  spec.email = ['brett@phillips-vickers.com']
11
11
  spec.description = 'CSV based Ruby decision tables.'
@@ -32,10 +32,11 @@ module CSVDecision
32
32
  data = input_hashes.data(decision: decision, path: path, input: input)
33
33
  next if data == {}
34
34
 
35
+ # Note that +rows+ must be enclosed in an array for this method to work.
35
36
  result = decision.index_scan_first_match(
36
37
  scan_cols: data[:scan_cols],
37
38
  hash: data[:hash],
38
- index_rows: Array(rows)
39
+ index_rows: [rows]
39
40
  )
40
41
  return result if result != {}
41
42
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: csv_decision
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Vickers