Skip to content

Commit

Permalink
Don't double expand a graph object when container is @index and `@g…
Browse files Browse the repository at this point in the history
…raph`.
  • Loading branch information
gkellogg committed Jan 3, 2020
1 parent 889b125 commit ab5d1a2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion index.html
Expand Up @@ -2892,7 +2892,8 @@ <h3>Algorithm</h3>
and {{JsonLdOptions/ordered}} flags</span>.</li>
<li>For each <var>item</var> in <var>index value</var>:
<ol class="algorithm changed">
<li>If <var>container mapping</var> includes <code>@graph</code>,
<li id="alg-expand-container-index-graph">If <var>container mapping</var> includes <code>@graph</code>,
<span class="changed">and <var>item</var> is not a <a>graph object</a>,</span>
set <var>item</var> to a new <a>map</a> containing the key-value pair
<code>@graph</code>-<var>item</var>,
ensuring that the value is represented using an <a>array</a>.</li>
Expand Down Expand Up @@ -7019,6 +7020,9 @@ <h2>Changes since Candidate Release of 12 December 2019</h2>
step <a href="#api-expand-post-processing">7.1</a> of
the <a data-link-for="JsonLdProcessor">expand()</a> method of the
<a>JsonLdProcessor</a> interface.
Additionally, in step <a href="#alg-expand-container-index-graph">13.8.3.7.1</a>,
when expanding properties where container includes both `@index` and `@graph`,
don't transform an item into a <a>graph object</a> repetitively.
This corrects an issue introduced in <a href="https://github.com/w3c/json-ld-api/pull/184">PR 184</a> and is
in response to <a href="https://github.com/w3c/json-ld-api/issues/294">Issue 294</a>.</li>
</ul>
Expand Down

0 comments on commit ab5d1a2

Please sign in to comment.