File tree Expand file tree Collapse file tree 1 file changed +0
-15
lines changed 
liveness/src/main/java/com/amplifyframework/ui/liveness/camera Expand file tree Collapse file tree 1 file changed +0
-15
lines changed Original file line number Diff line number Diff line change @@ -46,9 +46,7 @@ import com.amplifyframework.ui.liveness.model.LivenessCheckState
4646import  com.amplifyframework.ui.liveness.state.LivenessState 
4747import  com.amplifyframework.ui.liveness.util.WebSocketCloseCode 
4848import  java.util.Date 
49- import  java.util.Timer 
5049import  java.util.concurrent.Executors 
51- import  kotlin.concurrent.schedule 
5250import  kotlin.coroutines.resume 
5351import  kotlin.coroutines.suspendCoroutine 
5452import  kotlinx.coroutines.MainScope 
@@ -253,18 +251,6 @@ internal class LivenessCoordinator(
253251    }
254252
255253    private  fun  processFinalEventsSent () {
256-         //  Timeout if the disconnect event isn't received (onComplete isn't invoked) within the time limit
257-         Timer ().schedule(DISCONNECT_EVENT_TIMEOUT_MS ) {
258-             if  (! disconnectEventReceived) {
259-                 val  timeoutError = 
260-                     FaceLivenessDetectionException .SessionTimedOutException (
261-                         " Session timed out. Did not receive final response from server within " + 
262-                             " time limit." 
263-                     )
264-                 processSessionError(timeoutError, true )
265-             }
266-             cancel()
267-         }
268254        unbindCamera(context)
269255    }
270256
@@ -309,6 +295,5 @@ internal class LivenessCoordinator(
309295        const  val  TARGET_ENCODE_BITRATE  =  (1024  *  1024  *  .6 ).toInt()
310296        const  val  TARGET_ENCODE_KEYFRAME_INTERVAL  =  1  //  webm muxer only flushes to file on keyframe
311297        val  TARGET_RESOLUTION_SIZE  =  Size (TARGET_WIDTH , TARGET_HEIGHT )
312-         const  val  DISCONNECT_EVENT_TIMEOUT_MS :  Long  =  8000 
313298    }
314299}
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments