fix json_valid return type

don't want mysql to try to parse a string that isn't there...