stopAudio method

Future<void> stopAudio()

Implementation

Future<void> stopAudio() async {
  // Ensure the file path is correct and accessible from the web directory
  await _audioPlayer.stop();
  await _audioPlayer.dispose();
}