ach 0.6.1 → 0.6.2

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: 2675fc4115782f0d7fca900b070cebd739e9ceceee0c32d197b0ecd24e56f985
4
- data.tar.gz: 3cb59f5617acdad57d7272124ca83999313c7675d48239a3cc0e510dcb095130
3
+ metadata.gz: 899d1e91f92c6c42821e2f42d3cc81e6b06f5ea5dd616db9c99bb7fa702fc58e
4
+ data.tar.gz: c8cd8f1f83ebba1410cb1839c73163d50e708edff4564749b4767fc1ca79de37
5
5
  SHA512:
6
- metadata.gz: 8426fe5b8944fb11d7ca51bbc631a14f64e9e5dbd7ca668833905ac0f05b14c8f91248b4f43ff0c8245f705ec0b07e8588cb168ba82bb7160a880965414bbdfa
7
- data.tar.gz: 5b403f8700e4ecc92f41f619f960455df6d88538f989ba3a545f28ff98632506dfeb76753622ff4d7ffbeecba71d91783110cb555cb4021097be9a71d2e9fdfd
6
+ metadata.gz: '0646039b6300cca2a16db69cc4fad9f6f3963c7e2bceb34a7ab036aded15d2e3aeff2dd4a0865e3b0badbcf5d7e51485d986d75c60e5b2f12b826cf46dd9f625'
7
+ data.tar.gz: 3db2e6220ffa894248dc36e98be580a075428047ddf815c2f049e082a121e54172a87d932801720a2746da3e8388015bafb9dc0e0aed8bef483d86aca5807e2f
data/lib/ach/ach_file.rb CHANGED
@@ -166,7 +166,7 @@ module ACH
166
166
  Date.today.to_datetime + (same_day_hour + same_day_minute/60) / 24
167
167
  end
168
168
 
169
- date_time || Data.parse(date_string)
169
+ date_time || ACH::Data.parse(date_string)
170
170
  rescue
171
171
  date_string
172
172
  end
@@ -1,12 +1,15 @@
1
1
  module ACH
2
2
  module StringFormattingHelper
3
- # Passing in SD to the date signifies same-day to banks. This is used for the company_descriptive_date
3
+ # Passing in SD to the date signifies same-day to banks. This is used for
4
+ # the company_descriptive_date
4
5
  def self.stringify_with_same_day(f)
5
6
  return f.upcase if f.to_s.upcase.match(/^SD\d+$/)
6
7
 
7
- Date.strptime(f, '%y%m%d')
8
- rescue
9
- f
8
+ if f.respond_to?(:strftime)
9
+ f = f.strftime('%y%m%d')
10
+ end
11
+
12
+ f[0..5].rjust(6)
10
13
  end
11
14
  end
12
15
  end
data/lib/ach/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module ACH
2
- VERSION = '0.6.1'.freeze
2
+ VERSION = '0.6.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ach
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.1
4
+ version: 0.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jared Morgan
8
8
  - Josh Puetz
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2023-03-07 00:00:00.000000000 Z
12
+ date: 2023-03-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: appraisal
@@ -110,7 +110,7 @@ files:
110
110
  homepage: https://github.com/jm81/ach
111
111
  licenses: []
112
112
  metadata: {}
113
- post_install_message:
113
+ post_install_message:
114
114
  rdoc_options: []
115
115
  require_paths:
116
116
  - lib
@@ -125,8 +125,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
125
125
  - !ruby/object:Gem::Version
126
126
  version: '0'
127
127
  requirements: []
128
- rubygems_version: 3.0.9
129
- signing_key:
128
+ rubygems_version: 3.3.25
129
+ signing_key:
130
130
  specification_version: 4
131
131
  summary: Helper for building ACH files
132
132
  test_files: []