Fixup some bad and missing returns

I was crashing the endpoint with malformed JSON. Now it doesn't crash.