Support passing of metadata to OResult with OContextualRecordId
package com.orientechnologies.orient.core.sql.executor;
import com.orientechnologies.orient.core.db.record.OIdentifiable;
+import com.orientechnologies.orient.core.id.OContextualRecordId;
import com.orientechnologies.orient.core.record.OElement;
import com.orientechnologies.orient.core.record.impl.OBlob;
import com.orientechnologies.orient.core.record.impl.ODocument;
@@ -159,6 +160,9 @@ public class OResultInternal implements OResult {
} else {
this.element = element;
}
+ if (element instanceof OContextualRecordId) {
+ this.addMetadata(((OContextualRecordId) element).getContext());
+ }
}
@Override
