Skip to content

Commit

Permalink
don't start the citeproc processor if the input doesn't contain citat…
Browse files Browse the repository at this point in the history
…ions
  • Loading branch information
Elena Krippner committed Dec 19, 2023
1 parent c004e5f commit e69d14b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions render/src/render.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ impl<'a> Context<'a> {
}

fn new(doc: &'a Document, format: OutputFormatKind) -> Self {
if doc.citations.is_empty() {
return Context {
doc,
rendered_citations: vec![],
footnotes: "".to_string(),
bibliography: "".to_string(),
};
}
let rendered_citations: Vec<String>;
let footnotes: String;
let bibliography: String;
Expand Down

0 comments on commit e69d14b

Please sign in to comment.