huskies: merge 964
This commit is contained in:
@@ -273,8 +273,8 @@ pub fn write_item(
|
||||
if stage_changed {
|
||||
// Read the current name from the CRDT document for the event.
|
||||
let current_name = match state.crdt.doc.items[idx].name.view() {
|
||||
JsonValue::String(s) if !s.is_empty() => Some(s),
|
||||
_ => None,
|
||||
JsonValue::String(s) if !s.is_empty() => s,
|
||||
_ => String::new(),
|
||||
};
|
||||
// Storage seam: convert the old raw CRDT stage string to a typed Stage.
|
||||
let from_stage = old_stage.and_then(|s| Stage::from_dir(&s));
|
||||
@@ -336,7 +336,7 @@ pub fn write_item(
|
||||
story_id: story_id.to_string(),
|
||||
from_stage: None,
|
||||
to_stage: stage.clone(),
|
||||
name: name.map(String::from),
|
||||
name: name.unwrap_or("").to_string(),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user