Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^3: Getting error while decoding JSON object via POST method

by tobyink (Abbot)
on Feb 06, 2013 at 09:59 UTC ( #1017371=note: print w/replies, xml ) Need Help??


in reply to Re^2: Getting error while decoding JSON object via POST method
in thread Getting error while decoding JSON object via POST method

This error message occurs when you pass the empty string or an undefined variable to be decoded by JSON, JSON::PP or JSON::XS.

So I'd suggest that even with the updated code, the problem is related to the initialization of $jsonText - it appears to be undef.

package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1017371]
help
Chatterbox?
[james28909]: i need to fix this issue with perlmonks. i keep having the issue of someone posting something that casues the page to be very wide.
[james28909]: is there some setting i am missing?
[GrandFather]: It's either lines that your browser won't split (no white space) or nodes with <pre> tags which ought to be code tags

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (3)
As of 2017-05-24 00:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?