Saving PFObject NSCoding

后端 未结 4 2092
清歌不尽
清歌不尽 2021-02-14 07:45

My Problem: saveInBackground isn\'t working.

The Reason It\'s not working: I\'m saving PFObjects stored in an

4条回答
  •  别跟我提以往
    2021-02-14 07:51

    As you said in your question, the null fields must be screwing up the saveInBackground calls.

    The weird thing is that the parseClassName is also null, while this must probably be required by Parse to save it. Is it set before you save your NSArray in the file ?

    So I see two solutions :

    • implementing yourself NSCoding without the null fields, but if the object has already been saved on the server, it's useful (even necessary) to save its objectIds, createdAt, updatedAt fields, etc...
    • save each PFObject on Parse before saving your NSArray in a file, so those fields won't be null.

提交回复
热议问题