You did the right thing, but the line wrapping rules here make me sad.

Also, if you wanted you could probably change the way the JSON is generated to understand how to serialize a list.