Skip to content

Commit

Permalink
fix(GiniCaptureSDK): Fix indentation
Browse files Browse the repository at this point in the history
PIA-4460
  • Loading branch information
zladzeyka committed Sep 5, 2023
1 parent a3febaa commit aea6141
Showing 1 changed file with 45 additions and 45 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -509,56 +509,56 @@ import GiniBankAPILibrary
iban: String,
bic: String,
amountToPay: ExtractionAmount) {
guard let documentService = documentService else { return }

let formattedPriceValue = amountToPay.value.stringValue(withDecimalPoint: 2) ?? "\(amountToPay.value)"
let amountToPayString = "\(formattedPriceValue)" + ":" + amountToPay.currency.rawValue

let paymentRecipientExtraction = Extraction(box: nil,
candidates: nil,
entity: "companyname",
value: paymentRecipient,
name: "paymentRecipient")
let paymentReferenceExtraction = Extraction(box: nil,
candidates: nil,
entity: "reference",
value: paymentReference,
name: "paymentReference")
let paymentPurposeExtraction = Extraction(box: nil,
candidates: nil,
entity: "text",
value: paymentPurpose,
name: "paymentPurpose")
let ibanExtraction = Extraction(box: nil,
candidates: nil,
entity: "iban",
value: iban,
name: "iban")
let bicExtraction = Extraction(box: nil,
guard let documentService = documentService else { return }

let formattedPriceValue = amountToPay.value.stringValue(withDecimalPoint: 2) ?? "\(amountToPay.value)"
let amountToPayString = "\(formattedPriceValue)" + ":" + amountToPay.currency.rawValue

let paymentRecipientExtraction = Extraction(box: nil,
candidates: nil,
entity: "companyname",
value: paymentRecipient,
name: "paymentRecipient")
let paymentReferenceExtraction = Extraction(box: nil,
candidates: nil,
entity: "reference",
value: paymentReference,
name: "paymentReference")
let paymentPurposeExtraction = Extraction(box: nil,
candidates: nil,
entity: "text",
value: paymentPurpose,
name: "paymentPurpose")
let ibanExtraction = Extraction(box: nil,
candidates: nil,
entity: "bic",
value: bic,
name: "bic")
let amountExtraction = Extraction(box: nil,
candidates: nil,
entity: "amount",
value: amountToPayString,
name: "amountToPay")

let updatedExtractions: [Extraction] = [paymentRecipientExtraction,
paymentReferenceExtraction,
paymentPurposeExtraction,
ibanExtraction,
bicExtraction,
amountExtraction]
entity: "iban",
value: iban,
name: "iban")
let bicExtraction = Extraction(box: nil,
candidates: nil,
entity: "bic",
value: bic,
name: "bic")
let amountExtraction = Extraction(box: nil,
candidates: nil,
entity: "amount",
value: amountToPayString,
name: "amountToPay")

let updatedExtractions: [Extraction] = [paymentRecipientExtraction,
paymentReferenceExtraction,
paymentPurposeExtraction,
ibanExtraction,
bicExtraction,
amountExtraction]

documentService.sendFeedback(with: updatedExtractions, updatedCompoundExtractions: nil)

documentService.resetToInitialState()
self.documentService = nil
}
documentService.resetToInitialState()
self.documentService = nil
}
// swiftlint:enable function_parameter_count

/**
Enum that represents entry points used for launching the SDK.
*/
Expand Down

0 comments on commit aea6141

Please sign in to comment.