forked from friendica/php-json-ld
Sort RDF statement output.
This commit is contained in:
parent
566991cb47
commit
18e2934981
|
@ -483,11 +483,12 @@ class JsonLdProcessor {
|
|||
if(isset($options['format'])) {
|
||||
// supported formats
|
||||
if($options['format'] === 'application/nquads') {
|
||||
$nquads = '';
|
||||
$nquads = array();
|
||||
foreach($statements as $statement) {
|
||||
$nquads .= $this->_toNQuad($statement);
|
||||
$nquads[] = $this->_toNQuad($statement);
|
||||
}
|
||||
$statements = $nquads;
|
||||
sort($nquads);
|
||||
$statements = implode($nquads);
|
||||
}
|
||||
else {
|
||||
throw new JsonLdException(
|
||||
|
|
Loading…
Reference in a new issue