From 4f3def3c12a9f63537b0d9c94158133ee918b66f Mon Sep 17 00:00:00 2001 From: Aditya <75937365+TheAdityaGupta@users.noreply.github.com> Date: Fri, 15 Mar 2024 16:59:35 +0530 Subject: [PATCH] Update CameraActivity.kt App goes to a black screen when back is pressed. Fixed that --- app/src/main/java/com/miniai/liveness/CameraActivity.kt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/miniai/liveness/CameraActivity.kt b/app/src/main/java/com/miniai/liveness/CameraActivity.kt index 1406b95..8da4f59 100644 --- a/app/src/main/java/com/miniai/liveness/CameraActivity.kt +++ b/app/src/main/java/com/miniai/liveness/CameraActivity.kt @@ -147,4 +147,8 @@ class CameraActivity : AppCompatActivity(), FrameInferface { override fun onVerify(msg: String) { } -} \ No newline at end of file + override fun onBackPressed() { + finishAffinity() + super.onBackPressed() + } +}