table_print 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -34,10 +34,10 @@ module TablePrint
34
34
  cells = {}
35
35
  handleable_columns(hash).each do |method|
36
36
  display_method = (prefix == "" ? method : "#{prefix}.#{method}")
37
- if target.is_a? Hash
38
- cell_value = target[method.to_sym]
39
- elsif method.is_a? Proc
37
+ if method.is_a? Proc
40
38
  cell_value = method.call(target)
39
+ elsif target.is_a? Hash
40
+ cell_value = target[method.to_sym]
41
41
  else
42
42
  cell_value ||= target.send(method)
43
43
  end
@@ -1,4 +1,4 @@
1
1
  module TablePrint
2
- VERSION = "1.1.0"
2
+ VERSION = "1.1.1"
3
3
  end
4
4
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: table_print
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 0
10
- version: 1.1.0
9
+ - 1
10
+ version: 1.1.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Chris Doyle