rightsignature-railstyle 1.1.9 → 1.1.10

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: d6dac84b987a3973b7100641164500f413f80746
4
- data.tar.gz: 5e5f3de36c945c0ea489af01545306a2b20914a5
3
+ metadata.gz: 0dd8c30953726df1a4247249a5e3bc1a6431b8db
4
+ data.tar.gz: 5b662b919135842c68b105a23555a62f1f3ab0ec
5
5
  SHA512:
6
- metadata.gz: e64eb512785e4a09a1be4448edd8111f50491d3ff3914f363ed50747d2c7d9c59e6dded30d5aaad5cbc60861789ae5b217dd91527234459d18b022d9fb1b6b9e
7
- data.tar.gz: 840e1bcacf410f46eb61a661907ebb4f7a6b3cdd6b0316b11eb2a9c1f2676b581f28c0c6dba89757510d7b818507810d944ccf36014c041ad9963526ed7b1b76
6
+ metadata.gz: 78916d01bc9f350c373b6db6c9beaf73e46a525a40c6ff359af3fa7e934d73791a19ba1f43ce45b34a0b9bd12542f2518fbcc404b34f707e5304e94376199d44
7
+ data.tar.gz: 3d6b94cc8b10f619e8e343953e824334079c1c86536cfa0e4f814c58ba28a462e6e729ff3d7fed8730165e5aed5ce6cc11cb71d756cc9dfe07cfdb50bd43cbc8
data/Gemfile CHANGED
@@ -1,2 +1,4 @@
1
1
  source :rubygems
2
2
  gemspec
3
+
4
+ gem 'pry'
@@ -1,4 +1,3 @@
1
- require 'pry'
2
1
  module RightSignature::Helpers #:nodoc:
3
2
  module TagsHelper #:nodoc:
4
3
  class <<self #:nodoc:
@@ -63,19 +63,21 @@ module RightSignature
63
63
  # Note: Must check if it's a deeply nested hash instead, since that is what occurs
64
64
  # for single-item XLM "arrays"
65
65
  # {..., recipients: {recipient: [{...},{...}]}} => {..., recipients: {...: {...}, ...:{...}}}
66
- tmp = doc[:recipients][:recipient].is_a?(Hash) ? [doc[:recipients][:recipient]] : doc[:recipients][:recipient]
67
- doc[:recipients] = tmp.reduce({}){|h, v| h[v[:role_id]] = v and h}
66
+ tmp = doc[:recipients] && (doc[:recipients][:recipient].is_a?(Hash) ? [doc[:recipients][:recipient]] : doc[:recipients][:recipient])
67
+ doc[:recipients] = tmp.reduce({}){|h, v| h[v[:role_id]] = v and h} if tmp
68
68
 
69
- tmp = doc[:audit_trails][:audit_trail].is_a?(Hash) ? [doc[:audit_trails][:audit_trail]] : doc[:audit_trails][:audit_trail]
70
- doc[:audit_trails] = tmp.reduce({}){|h, v| h[v[:timestamp]] = v and h}
69
+ tmp = doc[:audit_trails] && doc[:audit_trails][:audit_trail].is_a?(Hash) ? [doc[:audit_trails][:audit_trail]] : doc[:audit_trails][:audit_trail]
70
+ doc[:audit_trails] = tmp.reduce({}){|h, v| h[v[:timestamp]] = v and h} if tmp
71
71
 
72
- tmp = doc[:form_fields][:form_field].is_a?(Hash) ? [doc[:form_fields][:form_field]] : doc[:form_fields][:form_field]
73
- doc[:form_fields] = tmp.reduce({}){|h, v| h[v[:name]] = v and h}
72
+ tmp = doc[:form_fields] && doc[:form_fields][:form_field].is_a?(Hash) ? [doc[:form_fields][:form_field]] : doc[:form_fields][:form_field]
73
+ doc[:form_fields] = tmp.reduce({}){|h, v| h[v[:name]] = v and h} if tmp
74
74
 
75
75
  # Extract a few fields from a deeply nested array
76
- tmp = doc[:pages][:page].is_a?(Hash) ? doc[:pages][:page] : doc[:pages][:page].first
77
- %i(original_template_guid original_template_filename).each do |sym|
78
- doc[sym] = tmp[sym]
76
+ tmp = doc[:pages] && doc[:pages][:page].is_a?(Hash) ? doc[:pages][:page] : doc[:pages][:page].first
77
+ if tmp
78
+ %i(original_template_guid original_template_filename).each do |sym|
79
+ doc[sym] = tmp[sym]
80
+ end
79
81
  end
80
82
  doc.delete(:pages)
81
83
 
@@ -1,3 +1,3 @@
1
1
  module RightSignature
2
- VERSION = "1.1.9"
2
+ VERSION = "1.1.10"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rightsignature-railstyle
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.9
4
+ version: 1.1.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Barone
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-21 00:00:00.000000000 Z
11
+ date: 2017-03-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -136,7 +136,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
136
136
  version: '0'
137
137
  requirements: []
138
138
  rubyforge_project:
139
- rubygems_version: 2.6.8
139
+ rubygems_version: 2.6.11
140
140
  signing_key:
141
141
  specification_version: 4
142
142
  summary: API wrapper for RightSignature