diff --git a/CHANGELOG.md b/CHANGELOG.md index 9f95e79..fb33e12 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.1.8 + +* Fix bug in AndroidAudioManager.getMicrophones(). + ## 0.1.7 * Fix bug detecting added devices on iOS/macOS (@derekcoder). diff --git a/lib/src/android.dart b/lib/src/android.dart index ce2ea05..4b498ac 100644 --- a/lib/src/android.dart +++ b/lib/src/android.dart @@ -333,8 +333,8 @@ class AndroidAudioManager { /// (UNTESTED) Requires API level 28 Future> getMicrophones() async { - return ((await _channel.invokeListMethod>( - 'getMicrophones')) as List) + return ((await _channel.invokeMethod>('getMicrophones'))!) + .map((raw) => Map.from(raw)) .map((raw) => AndroidMicrophoneInfo( description: raw['description'], id: raw['id'], diff --git a/pubspec.yaml b/pubspec.yaml index ec15f01..1eb226c 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: audio_session description: Sets the iOS audio session category and Android audio attributes for your app, and manages your app's audio focus, mixing and ducking behaviour. -version: 0.1.7 +version: 0.1.8 homepage: https://github.com/ryanheise/audio_session environment: