mamund/media-types — pull request #33 by smizell (2014-03-22 19:32:36+00:00)
Title: Fix full JSON example

This took me a long while to figure out, but I think the JSON example needs some tweaking to make it the equivalent of the XML example. In the XML example, it looks like this (condensed):

```xml

```

The JSON variant is this (also condense, with comment to point out issue):

```javascript
{
"uber" :
{
"version" : "1.0",
"data" :
[
{"rel" : ["self"], "url" : "http://example.org/"},
{"rel" : ["profile"], "url" : "http://example.org/profiles/people-and-places"},

{
// Note this data element
"data" :
[
{
"id" : "people",
"rel" : ["collection","http://example.org/rels/people"],
"url" : "http://example.org/people/",
"data" : []
}
]
}
]
}
}
```

The item noted above makes for an extra, empty data element, which would be this in XML:

```xml

```

This pull request removes that extra data element. It's very hard to see without working with some code that is implementing this. To see the results in Hyperdescribe, view the [example in the repo](https://github.com/smizell/hyperdescribe-hal-json/blob/c849bffc63ee0ffabe2bad953ffe86bf23e94b45/examples/source.hyperdescribe.js).

Hope this makes sense. **Please check me to make sure I got this right!**