Prevent updating flashlight button state before turning updating flashlight
This commit is contained in:
parent
03b0fbb836
commit
d9d3928705
|
@ -168,9 +168,6 @@ class MyCameraImpl private constructor(private val context: Context, private var
|
|||
if (MyCameraImpl.cameraFlash == null) {
|
||||
MyCameraImpl.cameraFlash = CameraFlash(context, cameraTorchListener)
|
||||
}
|
||||
scope.launch {
|
||||
_flashlightOn.emit(isFlashlightOn)
|
||||
}
|
||||
} catch (e: Exception) {
|
||||
scope.launch {
|
||||
cameraError.emit(Unit)
|
||||
|
|
Loading…
Reference in New Issue