cmxl 1.4.2 → 1.4.3

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: e3e78d30d71b355b7ac3b69166d19b07f8c2476b0060fe62963367f817bfcef0
4
- data.tar.gz: 92e4ddeb3db1528466f80c60817bf851fb8ff736a27a360db7752b5ace03d1e6
3
+ metadata.gz: 0bd9ef8a843f9bf1a20ec1d857fea91c7d6f7367564c3e1ad70dcfac1d147296
4
+ data.tar.gz: b39969a388a04aafa2f6a0bde21bb6756b82b32ac9ce95e2133f300e2b7b0e21
5
5
  SHA512:
6
- metadata.gz: b7b08fef90747fb155744813e72e3e771d5e86d45d5e61a48742cb20d59aedb14663474f7a06600bcedaad7858d1f3d4706c4c7748e7444aff62564da796daf0
7
- data.tar.gz: 1f0d3b254dc14f10a37c275ccfb949356e5b37fa533aa0558fc0dbf11593e9f049d1593beae5bb4ce4e356732233b895d4b36c5a84d514944d47500ccb948243
6
+ metadata.gz: fe2990f15a8d062523319ec03c177576df2d65c976a62966eca5b819c5bdee41d4426a04b8d12ac05bf86b741e9532234e49cf1944e417496a2ccd0fa5725057
7
+ data.tar.gz: b48de56367942523dd1306d24b8abe8659c10a2d0d67cd7ac52ea7ee5b3f445191b7ad7e119682f5827cb4100fdb5dd5474b491e82ab1de646300d0a2e1367bb
@@ -1,3 +1,7 @@
1
+ # 1.4.3
2
+
3
+ - `[BUGFIX]` parse field identifier only at the beginning of lines
4
+
1
5
  # 1.4.2
2
6
 
3
7
  - `[ENHANCEMENT]` handles broken account data without blowing up
@@ -26,7 +26,7 @@ module Cmxl
26
26
  def parse!
27
27
  self.fields = []
28
28
 
29
- lines = source.split(/(:[0-9A-Z]{2,3}:)/m).reject(&:empty?).each_slice(2).map(&:join)
29
+ lines = source.split(/(^:[0-9A-Z]{2,3}:)/m).reject(&:empty?).each_slice(2).map(&:join)
30
30
 
31
31
  lines.map do |line|
32
32
  if line =~ /\A:86:/
@@ -99,7 +99,7 @@ module Cmxl
99
99
  end
100
100
 
101
101
  def mt942?
102
- fields.any? { |field| field.is_a?(Fields::FloorLimitIndicator) }
102
+ fields.any? { |field| field.is_a? Fields::FloorLimitIndicator }
103
103
  end
104
104
 
105
105
  def to_h
@@ -1,3 +1,3 @@
1
1
  module Cmxl
2
- VERSION = '1.4.2'.freeze
2
+ VERSION = '1.4.3'.freeze
3
3
  end
@@ -1,2 +1,2 @@
1
1
  :61:1409010902DR000000000001,62NTRF0000549855700010//025498557/000001
2
- :86:171?00SEPA LASTSCHRIFT KUNDE?10281?20KREF+EREF+TRX-0A4A47C3-F846-4729?21-8A1B-5DF620F?22MREF+CAC97D2144174318AC18D9?23BF815BD4FB?24CRED+DE98ZZZ09999999999?25SVWZ+FOO TRX-0A4A47C3-F84?266-4729-8A1B-5DF620F?30HYVEDEMMXXX?31HUkkbbbsssskcccccccccccccccx?32Peter Pan?99?34171
2
+ :86:171?00SEPA LASTSCHRIFT KUNDE?10281?20KREF+EREF+TRX-0A4A47C3-F846-4729?21-8A1B-5DF620F?22:FOO:MREF+CAC97D2144174318A?23BF815BD4FB?24CRED+DE98ZZZ09999999999?25SVWZ+FOO TRX-0A4A47C3-F84?266-4729-8A1B-5DF620F?30HYVEDEMMXXX?31HUkkbbbsssskcccccccccccccccx?32Peter Pan?99?34171
@@ -34,19 +34,19 @@ describe Cmxl do
34
34
  'name' => 'Peter Pan',
35
35
  'sepa' => {
36
36
  'KREF' => '',
37
- 'EREF' => 'TRX-0A4A47C3-F846-4729-8A1B-5DF620F',
38
- 'MREF' => 'CAC97D2144174318AC18D9BF815BD4FB',
37
+ 'EREF' => 'TRX-0A4A47C3-F846-4729-8A1B-5DF620F:FOO:',
38
+ 'MREF' => 'CAC97D2144174318ABF815BD4FB',
39
39
  'CRED' => 'DE98ZZZ09999999999',
40
40
  'SVWZ' => 'FOO TRX-0A4A47C3-F846-4729-8A1B-5DF620F'
41
41
  },
42
- 'information' => 'KREF+EREF+TRX-0A4A47C3-F846-4729-8A1B-5DF620FMREF+CAC97D2144174318AC18D9BF815BD4FBCRED+DE98ZZZ09999999999SVWZ+FOO TRX-0A4A47C3-F846-4729-8A1B-5DF620F',
42
+ 'information' => 'KREF+EREF+TRX-0A4A47C3-F846-4729-8A1B-5DF620F:FOO:MREF+CAC97D2144174318ABF815BD4FBCRED+DE98ZZZ09999999999SVWZ+FOO TRX-0A4A47C3-F846-4729-8A1B-5DF620F',
43
43
  'description' => 'SEPA LASTSCHRIFT KUNDE',
44
44
  'sub_fields' => {
45
45
  '00' => 'SEPA LASTSCHRIFT KUNDE',
46
46
  '10' => '281',
47
47
  '20' => 'KREF+EREF+TRX-0A4A47C3-F846-4729',
48
48
  '21' => '-8A1B-5DF620F',
49
- '22' => 'MREF+CAC97D2144174318AC18D9',
49
+ '22' => ':FOO:MREF+CAC97D2144174318A',
50
50
  '23' => 'BF815BD4FB',
51
51
  '24' => 'CRED+DE98ZZZ09999999999',
52
52
  '25' => 'SVWZ+FOO TRX-0A4A47C3-F84',
@@ -58,7 +58,7 @@ describe Cmxl do
58
58
  '34' => '171'
59
59
  },
60
60
  'transaction_code' => '171',
61
- 'details' => '?00SEPA LASTSCHRIFT KUNDE?10281?20KREF+EREF+TRX-0A4A47C3-F846-4729?21-8A1B-5DF620F?22MREF+CAC97D2144174318AC18D9?23BF815BD4FB?24CRED+DE98ZZZ09999999999?25SVWZ+FOO TRX-0A4A47C3-F84?266-4729-8A1B-5DF620F?30HYVEDEMMXXX?31HUkkbbbsssskcccccccccccccccx?32Peter Pan?99?34171'
61
+ 'details' => '?00SEPA LASTSCHRIFT KUNDE?10281?20KREF+EREF+TRX-0A4A47C3-F846-4729?21-8A1B-5DF620F?22:FOO:MREF+CAC97D2144174318A?23BF815BD4FB?24CRED+DE98ZZZ09999999999?25SVWZ+FOO TRX-0A4A47C3-F84?266-4729-8A1B-5DF620F?30HYVEDEMMXXX?31HUkkbbbsssskcccccccccccccccx?32Peter Pan?99?34171'
62
62
  )
63
63
  }
64
64
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cmxl
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.2
4
+ version: 1.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Bumann
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-10-24 00:00:00.000000000 Z
11
+ date: 2019-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler