18 Mar 2014, 02:42
Generic-user-small

Marco Almeida (5 posts)

Hi CesareI have implemented very well the iCloud in my app using the example you have in your book. Tested on every simulator device and it all went well.

Also tested on iphone 4, 5 and 5s and iPads 2 and 3, all worked fine too.

But my app got rejected by app review team and I found out using and exception is at this line of code:

transactionLogsURL = [NSURL fileURLWithPath:coreDataCloudContent];

Before executing the code, I get no errors, not even warnings, but when I build and run I get this error on the console:

2014-03-17 23:36:01.053 manejoderisco[4803:1303] * Terminating app due to uncaught exception ‘NSInvalidArgumentException’, reason: ‘* -[NSURL initFileURLWithPath:]: nil string parameter’

So, I know I am getting a nil value, but the problem is that I don’t know how to fix, since, in my opinion the code has no issues, since I used the exact code you have in your book and I get no warning or errors.

So can you help me fix this?? I have sent you my AppDelegate.m which is where the problem is on line 181.

Thanks in advance, Best regards, Marco Almeida.

27 Mar 2014, 13:17
Mypic_pragsmall

Cesare Rocchi (15 posts)

Addressed privately via email. The issue when iCloud is turned off on the device, which leads to a nil URL.

  You must be logged in to comment