Skip to content

Commit

Permalink
fix: swift changes and caf packages version
Browse files Browse the repository at this point in the history
  • Loading branch information
thalesog committed Mar 7, 2023
1 parent b7bc1db commit b3b50d0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions caf-src/ios/CombateAFraude.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class CombateAFraude: RCTEventEmitter, PassiveFaceLivenessControllerDelegate, Do
@objc(passiveFaceLiveness:)
func passiveFaceLiveness(mobileToken: String) {
let passiveFaceLiveness = PassiveFaceLivenessSdk.Builder(mobileToken: mobileToken)
.enableMultiLanguage(enable: false)
.enableMultiLanguage(false)
.build()

DispatchQueue.main.async {
Expand Down Expand Up @@ -75,7 +75,7 @@ class CombateAFraude: RCTEventEmitter, PassiveFaceLivenessControllerDelegate, Do
func documentDetector(mobileToken: String, documentType: String) {
let documentDetectorBuilder = DocumentDetectorSdk.Builder(mobileToken: mobileToken)

_ = documentDetectorBuilder.enableMultiLanguage(enable: false)
_ = documentDetectorBuilder.enableMultiLanguage(false)

if (documentType == "RG"){
_ = documentDetectorBuilder.setDocumentDetectorFlow(flow :[
Expand Down Expand Up @@ -169,7 +169,7 @@ class CombateAFraude: RCTEventEmitter, PassiveFaceLivenessControllerDelegate, Do
@objc(faceAuthenticator:CPF:)
func faceAuthenticator(mobileToken: String, CPF: String) {
let faceAuthenticator = FaceAuthenticatorSdk.Builder(mobileToken: mobileToken)
.setPersonId(CPF)
// .setPersonId(CPF)
.build()

DispatchQueue.main.async {
Expand Down
12 changes: 6 additions & 6 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,23 +77,23 @@ const withCafIos: ConfigPlugin<void> = (config) => {
results = mergeContents({
tag: 'DocumentDetector',
src: results.contents,
newSrc: ` pod 'DocumentDetector'`,
newSrc: ` pod 'DocumentDetector', '~> 7.10.0'`,
anchor: /use_react_native!/,
offset: 0,
comment: '#',
})
results = mergeContents({
tag: 'PassiveFaceLiveness',
src: results.contents,
newSrc: ` pod 'PassiveFaceLiveness'`,
newSrc: ` pod 'PassiveFaceLiveness', '~> 5.25.0'`,
anchor: /use_react_native!/,
offset: 0,
comment: '#',
})
results = mergeContents({
tag: 'FaceAuthenticator',
src: results.contents,
newSrc: ` pod 'FaceAuthenticator'`,
newSrc: ` pod 'FaceAuthenticator', '~> 5.11.0'`,
anchor: /use_react_native!/,
offset: 0,
comment: '#',
Expand Down Expand Up @@ -266,9 +266,9 @@ const withCafAndroid: ConfigPlugin<void> = (config) => {
tag: 'Dependencies',
src: config.modResults.contents,
newSrc: `
implementation 'com.combateafraude.sdk:document-detector'
implementation 'com.combateafraude.sdk:passive-face-liveness'
implementation 'com.combateafraude.sdk:face-authenticator'
implementation 'com.combateafraude.sdk:document-detector:6.38.0'
implementation 'com.combateafraude.sdk:passive-face-liveness:5.25.12'
implementation 'com.combateafraude.sdk:face-authenticator:5.8.13'
`,
anchor: /dependencies {/,
offset: 1,
Expand Down

0 comments on commit b3b50d0

Please sign in to comment.