diff --git a/jsonld.php b/jsonld.php index 000f338..65c8d2b 100644 --- a/jsonld.php +++ b/jsonld.php @@ -2152,12 +2152,9 @@ class JsonLdProcessor { // special-case expand @id and @type (skips '@id' expansion) $prop = $this->_expandTerm($ctx, $property); - if($prop === '@id') { + if($prop === '@id' || $prop === '@type') { $rval = $this->_expandTerm($ctx, $value, $base); } - else if($prop === '@type') { - $rval = $this->_expandTerm($ctx, $value); - } else { // get type definition from context $type = self::getContextValue($ctx, $property, '@type');