Skip to content

Commit f7a9000

Browse files
committed
update host app code
1 parent b0a3688 commit f7a9000

File tree

4 files changed

+38
-2
lines changed

4 files changed

+38
-2
lines changed

HostApp/.gitignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#amplify-do-not-edit-begin
2+
amplify/\#current-cloud-backend
3+
amplify/.config/local-*
4+
amplify/logs
5+
amplify/mock-data
6+
amplify/mock-api-resources
7+
amplify/backend/amplify-meta.json
8+
amplify/backend/.temp
9+
build/
10+
dist/
11+
node_modules/
12+
aws-exports.js
13+
awsconfiguration.json
14+
amplifyconfiguration.json
15+
amplifyconfiguration.dart
16+
amplify-build-config.json
17+
amplify-gradle-config.json
18+
amplifytools.xcconfig
19+
.secret-*
20+
**.sample
21+
#amplify-do-not-edit-end

HostApp/HostApp.xcodeproj/project.pbxproj

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@
131131
9070FFBD285112B5009867D5 /* HostAppUITests */,
132132
9070FFA1285112B4009867D5 /* Products */,
133133
90215EED291E9FB60050F2AD /* Frameworks */,
134+
A5A9AF5054D0FF13505B212A /* AmplifyConfig */,
134135
);
135136
sourceTree = "<group>";
136137
};
@@ -213,6 +214,15 @@
213214
path = Model;
214215
sourceTree = "<group>";
215216
};
217+
A5A9AF5054D0FF13505B212A /* AmplifyConfig */ = {
218+
isa = PBXGroup;
219+
children = (
220+
973619242BA378690003A590 /* awsconfiguration.json */,
221+
973619232BA378690003A590 /* amplifyconfiguration.json */,
222+
);
223+
name = AmplifyConfig;
224+
sourceTree = "<group>";
225+
};
216226
/* End PBXGroup section */
217227

218228
/* Begin PBXNativeTarget section */

HostApp/HostApp/HostAppApp.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ struct HostAppApp: App {
2727

2828
init() {
2929
do {
30+
Amplify.Logging.logLevel = .verbose
3031
let auth = AWSCognitoAuthPlugin()
3132
let api = AWSAPIPlugin()
3233
try Amplify.add(plugin: auth)

HostApp/HostApp/Views/ExampleLivenessView.swift

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,12 @@ struct ExampleLivenessView: View {
4848
viewModel.presentationState = .error(.invalidSignature)
4949
case .failure(.cameraNotAvailable):
5050
viewModel.presentationState = .error(.cameraNotAvailable)
51-
default:
52-
viewModel.presentationState = .liveness
51+
case .failure(.validation):
52+
viewModel.presentationState = .error(.validation)
53+
case .failure(.faceInOvalMatchExceededTimeLimitError):
54+
viewModel.presentationState = .error(.faceInOvalMatchExceededTimeLimitError)
55+
case .failure(_):
56+
viewModel.presentationState = .error(.unknown)
5357
}
5458
}
5559
}

0 commit comments

Comments
 (0)