Skip to content

Commit

Permalink
[expo-av] Fix resume audio when in background (expo#9363)
Browse files Browse the repository at this point in the history
* [expo-av] Fix resume audio when in background

* [expo-av] Update changelog
IjzerenHein authored Jul 24, 2020
1 parent 35dcbeb commit 3ffff88
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -14,6 +14,7 @@
- Fix iOS stability issue due to player-item observers not cleaned up. ([#9350](https://github.com/expo/expo/pull/9350) by [@IjzerenHein](https://github.com/IjzerenHein))
- Fix duplicate full-screen will-dismiss event on iOS. ([#9366](https://github.com/expo/expo/pull/9366) by [@IjzerenHein](https://github.com/IjzerenHein))
- De-activate audio-session after unloading sound. ([#9365](https://github.com/expo/expo/pull/9365) by [@IjzerenHein](https://github.com/IjzerenHein))
- Fix resume audio when in background. ([#9363](https://github.com/expo/expo/pull/9363) by [@IjzerenHein](https://github.com/IjzerenHein))

## 8.3.0 — 2020-07-08

2 changes: 1 addition & 1 deletion ios/EXAV/EXAV.m
Original file line number Diff line number Diff line change
@@ -275,7 +275,7 @@ - (NSError *)promoteAudioSessionIfNecessary
if (!_audioIsEnabled) {
return UMErrorWithMessage(@"Expo Audio is disabled, so the audio session could not be activated.");
}
if (_isBackgrounded && ![_kernelAudioSessionManagerDelegate isActiveForModule:self]) {
if (_isBackgrounded && !_staysActiveInBackground && ![_kernelAudioSessionManagerDelegate isActiveForModule:self]) {
return UMErrorWithMessage(@"This experience is currently in the background, so the audio session could not be activated.");
}

0 comments on commit 3ffff88

Please sign in to comment.