From a9bf09db1e7bb4ee2b84fd3cb4f31e29da98a541 Mon Sep 17 00:00:00 2001 From: Tobie Morgan Hitchcock Date: Thu, 2 Jun 2022 09:07:28 +0100 Subject: [PATCH] Ensure edges are stored before indexes in RELATE statements --- lib/src/doc/relate.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/doc/relate.rs b/lib/src/doc/relate.rs index 49506dd9..b481713a 100644 --- a/lib/src/doc/relate.rs +++ b/lib/src/doc/relate.rs @@ -22,10 +22,10 @@ impl<'a> Document<'a> { self.field(ctx, opt, txn, stm).await?; // Check if allowed self.allow(ctx, opt, txn, stm).await?; - // Store index data - self.index(ctx, opt, txn, stm).await?; // Store record edges self.edges(ctx, opt, txn, stm).await?; + // Store index data + self.index(ctx, opt, txn, stm).await?; // Store record data self.store(ctx, opt, txn, stm).await?; // Run table queries