Skip to main content

parse_journal

Function parse_journal 

Source
pub fn parse_journal(
    text: &str,
    path: &Path,
    journal_root: &Path,
) -> Result<Journal, WorktreeCopyError>
Expand description

What: Parses and validates one journal’s text, refusing every shape recovery cannot trust. Why: Recovery turns journal paths into deletions, so every relation between the paths is checked first.

In TS you’d write (pseudocode):

validateJournalValue({ value: JSON.parse(text), path, journalRoot });