Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
581 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 Reply

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.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...