change: compile_article now takes references to pathbufs

This commit is contained in:
andrew 2026-04-21 14:54:10 -04:00
parent 32778e8fff
commit a5b42ea97a
2 changed files with 3 additions and 3 deletions

View file

@ -7,8 +7,8 @@ use typst_html::{HtmlAttr, HtmlDocument, HtmlElement, HtmlNode};
pub fn compile_article(
article_dir: PathBuf,
prepend: Option<PathBuf>,
article_dir: &PathBuf,
prepend: &Option<PathBuf>,
) -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
let template_file = article_dir.join("index.typ");

View file

@ -21,7 +21,7 @@ fn main() {
let args = Args::parse();
if let Err(e) = compile_article(args.dir, args.prepend) {
if let Err(e) = compile_article(&args.dir, &args.prepend) {
eprintln!("{e}");
std::process::exit(1);
}