From bfc69c8104bd00f0ae955242ff74900e0896d6a1 Mon Sep 17 00:00:00 2001 From: folex <0xdxdy@gmail.com> Date: Thu, 29 Oct 2020 15:35:05 +0300 Subject: [PATCH] Make prev_data a list by default --- aquamarine-vm/src/aquamarine_stepper_vm.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aquamarine-vm/src/aquamarine_stepper_vm.rs b/aquamarine-vm/src/aquamarine_stepper_vm.rs index b4e2902e..31e57f26 100644 --- a/aquamarine-vm/src/aquamarine_stepper_vm.rs +++ b/aquamarine-vm/src/aquamarine_stepper_vm.rs @@ -73,7 +73,7 @@ impl AquamarineVM { let prev_data_path = self.particle_data_store.join(particle_id); // TODO: check for errors related to invalid file content (such as invalid UTF8 string) - let prev_data = std::fs::read_to_string(&prev_data_path).unwrap_or(String::from("{}")); + let prev_data = std::fs::read_to_string(&prev_data_path).unwrap_or(String::from("[]")); let args = vec![ IValue::String(init_user_id.into()), IValue::String(aqua.into()),