mirror of
https://github.com/loro-dev/loro.git
synced 2025-02-06 12:25:03 +00:00
chore: rebase
This commit is contained in:
parent
815b95d126
commit
4cfdbff768
3 changed files with 4 additions and 4 deletions
|
@ -112,7 +112,7 @@ impl LogStore {
|
|||
fn get_events(&mut self, context: &mut ImportContext) -> Vec<RawEvent> {
|
||||
let deleted = self.with_hierarchy(|_, h| h.take_deleted());
|
||||
let mut events = Vec::with_capacity(context.diff.len());
|
||||
let mut h = self.hierarchy.try_lock().unwrap();
|
||||
let h = self.hierarchy.try_lock().unwrap();
|
||||
let reg = &self.reg;
|
||||
for (id, diff) in std::mem::take(&mut context.diff)
|
||||
.into_iter()
|
||||
|
|
|
@ -281,7 +281,7 @@ fn test_encode_state_map() {
|
|||
}
|
||||
|
||||
#[test]
|
||||
fn fields_sort_immutable() {
|
||||
fn fix_fields_order() {
|
||||
// ContainerType ContainerID Index ID
|
||||
// TotalOrderStamp RemoteContent MapSet ListOp DeleteSpan ListSlice (mod test)
|
||||
let id = ID::new(0, 1);
|
||||
|
|
|
@ -141,12 +141,12 @@ impl Loro {
|
|||
|
||||
#[wasm_bindgen(js_name = "exportSnapshot")]
|
||||
pub fn export_snapshot(&self) -> JsResult<Vec<u8>> {
|
||||
Ok(self.0.encode_snapshot())
|
||||
Ok(self.0.encode_snapshot(false))
|
||||
}
|
||||
|
||||
#[wasm_bindgen(js_name = "importSnapshot")]
|
||||
pub fn import_snapshot(input: Vec<u8>) -> Self {
|
||||
let core = LoroCore::decode_snapshot(&input, None, Default::default());
|
||||
let core = LoroCore::decode_snapshot(&input, Default::default(), None);
|
||||
Self(core)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue