简体   繁体   中英

iOS 9 Facebook SDK Parse

I am using Parse pod and it allows me to use Facebook SDK for iOS.

I want to add support for iOS 9 for my application but I faced with few migration issues.

First of all is there any some steps how to update my code.

Do I need to update Parse first? and setup Facebook pods separately?

Also I found this link , but when I copy paste this to my .plist:

<key>NSAppTransportSecurity</key>
<dict>
    <key>NSExceptionDomains</key>
    <dict>
        <key>facebook.com</key>
        <dict>
            <key>NSIncludesSubdomains</key>
            <true/>                
            <key>NSExceptionRequiresForwardSecrecy</key>
            <false/>
        </dict>
        <key>fbcdn.net</key>
        <dict>
            <key>NSIncludesSubdomains</key>
            <true/>
            <key>NSExceptionRequiresForwardSecrecy</key>
            <false/>
        </dict>
        <key>akamaihd.net</key>
        <dict>
            <key>NSIncludesSubdomains</key>
            <true/>
            <key>NSExceptionRequiresForwardSecrecy</key>
            <false/>
        </dict>
    </dict>
</dict>

I get some issues, Xcode says that:

The data couldn't be read because it isn't in the correct format.

I think your info.plist may be like this

<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
    <key>facebook.com</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>                
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
    <key>fbcdn.net</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
    <key>akamaihd.net</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
  </dict>
</dict>

<dict>  <------ You couldn't add two dictionaries in one <key></key>
  <key>hogehoge</key>
</dict>

<key>fugafuga</key>

If so, you should move hogehoge as follows.

<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
    <key>facebook.com</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>                
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
    <key>fbcdn.net</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
    <key>akamaihd.net</key>
    <dict>
        <key>NSIncludesSubdomains</key>
        <true/>
        <key>NSExceptionRequiresForwardSecrecy</key>
        <false/>
    </dict>
  </dict>
  <key>hogehoge</key>
</dict>

<key>fugafuga</key>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM