let JSON allow_nonref encoding()

it will do the right thing for integers and nulls