简体   繁体   中英

Parse - enabling local datastore produces error

I am trying to enable Parse's local datastore and I am setting it up how they suggest in the manual:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

    [Parse enableLocalDatastore];
    [Parse setApplicationId:@"xxxxxxxxxxxxxx" clientKey:@"xxxxxxxxxxxxxx"];

    ...

I am getting this error:

*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: ''enableLocalDataStore' must be called before 'setApplicationId:clientKey:''

I have tried placing the enableLocalDatastore line below the setApplicationId line and I get the same error. I have not enabled cachePolicy either. What is going on?

在这里大胆的NEVERMIND-我已经启用了数据存储,并试图再次启用它...没有意识到,当我最初设置解析时,我已经启用了它。

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