in reply to Re^3: JSON.pm returning "false" instead of false
in thread JSON.pm returning "false" instead of false

It's a big app so I didn't want to bog anyone down with the details, although I should have provided a test case. Your answer actually brought me to the solution though. It turns out that the $self->render_json method from Mojo was not being over-ridden correctly, and was therefore never calling the "serialize" method just as you suggested. So, I thank you very much for giving me a hint and leading me down the correct path. Next time, I will provide a test case that demonstrates the issue a little more clearly.
  • Comment on Re^4: JSON.pm returning "false" instead of false

Replies are listed 'Best First'.
Re^5: JSON.pm returning "false" instead of false
by Anonymous Monk on Apr 13, 2010 at 13:10 UTC

    That's the point of making a minimal example.

    1. It is small enough to debug.
    2. It demonstrates the problem.

    When you do those steps, you often find the answer yourself. If not, you'll know what to look at in the simple examples for next time.

Re^5: JSON.pm returning "false" instead of false
by josh803316 (Beadle) on Apr 13, 2010 at 23:43 UTC
    Thanks for all your feedback, sadly I know this already I was just being lazy. Ishould have taken the time to create a complete working test example and in doing so I would have found the problem. I completely agree that creating a base case makes it much easier for people to comment on and often allows me to find the solution myself before asking anyone. Thanks again for all the feedback.