G'day:
Here's a wee isJson() bug for you. Repro case:

<cfoutput>
    <cfset s = "{'key':'value'}">
    isJson("#s#"): #isJson(s)#<br>
    <cftry>
    <cfdump var="#deserializeJson(s)#">
    <cfcatch>#cfcatch.message# #cfcatch.detail#<br></cfcatch>
    </cftry>
    <hr>
    <cfset s = '{"key":"value"}'>
    isJson('#s#'): #isJson(s)#<br>
    <cftry>
    <cfdump var="#deserializeJson(s)#">
    <cfcatch>#cfcatch.message# #cfcatch.detail#<br></cfcatch>
    </cftry>
    <br>
</cfoutput>

The first instance says "true" to the isJson() call, but then errors on the 
deserializeJson() call. isJson() is incorrect here: the string is not valid 
JSON.

Do with that info what you will: I just noticed it when testing something 
on ColdFusion for the Railo guys - they have similar but different issues - 
I just thought you might want to know.

Cheers.

-- 
Adam

-- 
-- 
online documentation: http://openbd.org/manual/
 http://groups.google.com/group/openbd?hl=en

--- 
You received this message because you are subscribed to the Google Groups "Open 
BlueDragon" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to