huskies: merge 865
This commit is contained in:
@@ -107,7 +107,7 @@ pub fn transition_to_frozen(story_id: &str) -> Result<TransitionFired, ApplyErro
|
||||
let item = read_typed(story_id)?.ok_or_else(|| ApplyError::NotFound(story_id.to_string()))?;
|
||||
let resume_dir = item.stage.dir_name().to_string();
|
||||
let transform = move |content: &str| -> String {
|
||||
crate::io::story_metadata::set_front_matter_field(content, "resume_to_stage", &resume_dir)
|
||||
crate::db::yaml_legacy::set_front_matter_field(content, "resume_to_stage", &resume_dir)
|
||||
};
|
||||
apply_transition(story_id, PipelineEvent::Freeze, Some(&transform))
|
||||
}
|
||||
@@ -118,7 +118,7 @@ pub fn transition_to_frozen(story_id: &str) -> Result<TransitionFired, ApplyErro
|
||||
/// the `resume_to_stage` field from the front matter.
|
||||
pub fn transition_to_unfrozen(story_id: &str) -> Result<TransitionFired, ApplyError> {
|
||||
let transform = |content: &str| -> String {
|
||||
crate::io::story_metadata::clear_front_matter_field_in_content(content, "resume_to_stage")
|
||||
crate::db::yaml_legacy::clear_front_matter_field_in_content(content, "resume_to_stage")
|
||||
};
|
||||
apply_transition(story_id, PipelineEvent::Unfreeze, Some(&transform))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user