From 97786003044470bc91b12aee1055cb03539fd5c8 Mon Sep 17 00:00:00 2001 From: Tobie Morgan Hitchcock Date: Sun, 20 Mar 2022 14:27:03 +0000 Subject: [PATCH] Ensure all index data is removed when defining an index --- lib/src/sql/statements/define.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/sql/statements/define.rs b/lib/src/sql/statements/define.rs index 6cb0a901..3f83349d 100644 --- a/lib/src/sql/statements/define.rs +++ b/lib/src/sql/statements/define.rs @@ -973,7 +973,7 @@ impl DefineIndexStatement { run.add_tb(opt.ns(), opt.db(), &self.what).await?; run.set(key, self).await?; // Remove the index data - let key = crate::key::index::new(opt.ns(), opt.db(), &self.what, &self.name, Value::None); + let key = crate::key::guide::new(opt.ns(), opt.db(), &self.what, &self.name); run.delp(key, u32::MAX).await?; // Release the transaction drop(run);