Просмотр исходного кода

refactor: dont store unneeded indirections

Sam Jaffe 1 год назад
Родитель
Сommit
561bd5d24c
1 измененных файлов с 1 добавлено и 0 удалено
  1. 1 0
      include/jvalidate/schema.h

+ 1 - 0
include/jvalidate/schema.h

@@ -199,6 +199,7 @@ private:
     // to store it uniquely. Draft2019_09 supports directly extending a $ref schema
     // in the same schema, instead of requiring an allOf clause.
     if (node->is_pure_reference()) {
+      node = *node->reference_schema();
       cache_.erase(it);
       return alias(context.where, node);
     }