Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
583 views
in Technique[技术] by (71.8m points)

ios - How to properly set UIRequiredDeviceCapabilities?

I have had an app rejected by Apple stating that I need to implement UIRequiredDeviceCapabilities in my info.plist due to my app requiring a camera flash. I understand the issue but I am not sure how to properly set this key. Do I create UIRequiredDeviceCapabilities as a dictionary or array? and camera-flash as a bool or string? Any help is appreciated! Thanks!

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Add this text to your app's Info.plist file:

<key>UIRequiredDeviceCapabilities</key>
<array>
    <string>camera-flash</string>
</array>

You only need a dictionary if some of the capability requirements need to be false.

Important note from docs:

For app updates, you can only maintain or relax capability requirements. Submitting an update with added requirements would prevent some customers who previously downloaded your app from running the update.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...