Blank JSON String Throws Error

Hunter's Avatar

Hunter

21 Aug, 2009 05:47 PM

It appears that if a blank/empty JSON string comes across, it is still sent to the parser, which then reports an error:

Download Connection Error: Error Domain=org.brautaset.JSON.ErrorDomain Code=11 UserInfo=0x2153e70 "Unexpected end of string"

I can confirm that the JSON request in this example was just [] - no data.

It appears that other projects using SBJSON have opted not to send to the parser if there's nothing to parse:
http://yfactorial.lighthouseapp.com/projects/18393/tickets/17-json-...

  1. 2 Posted by System on 25 Aug, 2009 05:25 PM

    System's Avatar

    A Lighthouse ticket was created for this discussion

  2. Support Staff 3 Posted by Caged on 25 Aug, 2009 05:25 PM

    Caged's Avatar

    Thanks for the report. I'll have a look.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac

Recent Discussions

19 Jun, 2013 06:50 PM
17 Jul, 2011 06:47 AM
15 Jun, 2011 08:41 AM
15 Jun, 2011 02:53 AM
23 Feb, 2011 06:10 PM

 

15 Jan, 2011 11:13 PM
02 Jan, 2011 06:35 AM
12 Oct, 2010 11:49 PM
28 Aug, 2010 06:49 PM
24 Aug, 2010 05:12 PM
11 Aug, 2010 04:04 PM