On Sat, Feb 28, 2015 at 12:20 PM, Daniel Kinzler daniel.kinzler@wikimedia.de wrote:
Am 28.02.2015 um 11:57 schrieb Jeroen De Dauw:
Hey,
I think the serializer should just drop empty references
This seems like the wrong place do to that. I suggest to do this in the model itself, very similar to what we are doing with empty alias groups in lists of alias groups: https://github.com/wmde/WikibaseDataModel/blob/5c78e35ee1a382d3b132ddfd76077...
Sure, the model should do that.
And if the serializer encounters an empty reference for some reason, it should drop it, too. It's not a valid reference. There is no JSON binding for it.
The interesting question for me: How did they get in in the first place? And how do we prevent that? Both edits are fairly recent and from two different editors. This looks fishy to me.
Cheers Lydia