Skip to content

Commit

Permalink
Only end the recording session if one has been started
Browse files Browse the repository at this point in the history
  • Loading branch information
zwarm committed Jun 17, 2024
1 parent f63a589 commit acfa196
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,9 @@ class VoiceToContentViewModel @Inject constructor(

private fun onClose() {
logger.track(Stat.VOICE_TO_CONTENT_BUTTON_CLOSE_TAPPED)
recordingUseCase.endRecordingSession()
if (isRecording.value || isPaused.value) {
recordingUseCase.endRecordingSession()
}
_actionEvent.postValue(Dismiss)
}

Expand Down

0 comments on commit acfa196

Please sign in to comment.