mirror of
https://github.com/loro-dev/loro.git
synced 2025-02-02 11:06:14 +00:00
fix: checkout result err
This commit is contained in:
parent
fd0cc63cb5
commit
05f802376e
1 changed files with 5 additions and 6 deletions
|
@ -377,13 +377,12 @@ impl LoroDoc {
|
|||
let mut state = self.state.lock().unwrap();
|
||||
self.detached = true;
|
||||
let mut calc = self.diff_calculator.lock().unwrap();
|
||||
let Some(before) = &oplog.dag.frontiers_to_vv(&state.frontiers) else {
|
||||
let before = &oplog.dag.frontiers_to_vv(&state.frontiers).unwrap();
|
||||
let Some(after) = &oplog
|
||||
.dag
|
||||
.frontiers_to_vv(frontiers) else {
|
||||
return Err(LoroError::NotFoundError(format!("Cannot find the specified version {:?}", frontiers).into_boxed_str()))
|
||||
};
|
||||
let after = &oplog
|
||||
.dag
|
||||
.frontiers_to_vv(frontiers)
|
||||
.expect("The specified version is not found");
|
||||
let diff = calc.calc_diff_internal(
|
||||
&oplog,
|
||||
before,
|
||||
|
|
Loading…
Reference in a new issue