Skip to content

Commit 314d839

Browse files
committed
Add safe operator
1 parent 0cfe429 commit 314d839

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/cfonb/operation_details/ibe.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class IBE < Base
77

88
def self.apply(operation, line)
99
operation.creditor_identifier = line.detail[0..34].strip
10-
operation.creditor_identifier_type = line.detail[35..-1].strip
10+
operation.creditor_identifier_type = line.detail[35..-1]&.strip
1111
end
1212

1313
CFONB::OperationDetails.register('IBE', self)

lib/cfonb/operation_details/ipy.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class IPY < Base
77

88
def self.apply(operation, line)
99
operation.debtor_identifier = line.detail[0..34].strip
10-
operation.debtor_identifier_type = line.detail[35..-1].strip
10+
operation.debtor_identifier_type = line.detail[35..-1]&.strip
1111
end
1212

1313
CFONB::OperationDetails.register('IPY', self)

0 commit comments

Comments
 (0)