Skip to content

Commit

Permalink
Fixed one of the errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanpeach committed Dec 17, 2024
1 parent dd9d884 commit e237719
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/file/content/wikilink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,12 @@ impl Visitor for WikilinkVisitor {
.get(1)
.expect("The regex has 2 capture groups")
.start();
let sourcepos_start_offset_bytes =
SourceOffset::from_location(text, sourcepos.start.line, sourcepos.start.column)
.offset();
let sourcepos_start_offset_bytes = SourceOffset::from_location(
source,
sourcepos.start.line,
sourcepos.start.column,
)
.offset();
let span = SourceSpan::new(
(sourcepos_start_offset_bytes + capture_start_byte).into(),
alias.char_len(),
Expand Down

0 comments on commit e237719

Please sign in to comment.