Backgorund Mode: How to prevent the app from being rejected in the app store?

Hi everyone :slight_smile:

TLDR: App got rejected in Appstore, because it ‘declares support for audio in the UIBackgroundModes key in your Info.plist.’

In my current app I’m using background mode: https://ionicframework.com/docs/native/background-mode/.
The app is already published in the play store, but it got rejected from apple for the following reason:

Guideline 2.5.4 - Performance - Software Requirements


Your app declares support for audio in the UIBackgroundModes key in your Info.plist but did not include features that require persistent audio.

Next Steps

The audio key is intended for use by apps that provide audible content to the user while in the background, such as music player or streaming audio apps. Please revise your app to provide audible content to the user while the app is in the background or remove the "audio" setting from the UIBackgroundModes key.

How can I fix this? I don’t use (or need) audio while the app is in the background. I have no idea about native iOS methods or configurations. I allways relied on cordova for taking care about that! Any help would be much appreciated.

Found the solution here!

We have the following in config.xml to fix it:
<platform name=“ios”>

<edit-config file="*-Info.plist" mode=“overwrite” platform=“ios” target=“UIBackgroundModes”>
<array />
</edit-config>