mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-05-14 16:23:57 +02:00
Fix the retrieval of the doc in scope
This commit is contained in:
parent
c8b7822d0d
commit
44586e089d
@ -431,7 +431,7 @@ impl<'doc> Versions<'doc> {
|
||||
|
||||
let _ = engine.eval_ast_with_scope::<rhai::Dynamic>(&mut scope, edit_function).unwrap();
|
||||
data = RawMap::with_hasher_in(FxBuildHasher, doc_alloc);
|
||||
match scope.get_value::<Option<rhai::Map>>("doc").unwrap() {
|
||||
match scope.get_value::<rhai::Map>("doc") {
|
||||
Some(map) => {
|
||||
for (key, value) in map {
|
||||
let mut vec = bumpalo::collections::Vec::new_in(doc_alloc);
|
||||
@ -456,7 +456,7 @@ impl<'doc> Versions<'doc> {
|
||||
|
||||
let _ = engine.eval_ast_with_scope::<rhai::Dynamic>(&mut scope, edit_function).unwrap();
|
||||
data = RawMap::with_hasher_in(FxBuildHasher, doc_alloc);
|
||||
match scope.get_value::<Option<rhai::Map>>("doc").unwrap() {
|
||||
match scope.get_value::<rhai::Map>("doc") {
|
||||
Some(map) => {
|
||||
for (key, value) in map {
|
||||
let mut vec = bumpalo::collections::Vec::new_in(doc_alloc);
|
||||
|
Loading…
x
Reference in New Issue
Block a user