Skip to content

Commit

Permalink
Fixed an edge case with collecting backlinks
Browse files Browse the repository at this point in the history
Fixes #663.
  • Loading branch information
epwalsh committed Jul 26, 2024
1 parent fce967d commit 7b9feb6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- Added `opts.follow_img_func` option for customizing how to handle image paths.

### Fixed

- Fixed an edge case with collecting backlinks.

## [v3.9.0](https://github.com/epwalsh/obsidian.nvim/releases/tag/v3.9.0) - 2024-07-11

### Added
Expand Down
3 changes: 2 additions & 1 deletion lua/obsidian/client.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1310,7 +1310,8 @@ Client.find_backlinks_async = function(self, note, callback, opts)

-- Prepare search terms.
local search_terms = {}
for raw_ref in iter { tostring(note.id), note:fname(), self:vault_relative_path(note.path) } do
local note_path = Path.new(note.path)
for raw_ref in iter { tostring(note.id), note_path.name, note_path.stem, self:vault_relative_path(note.path) } do
for ref in
iter(util.tbl_unique {
raw_ref,
Expand Down

0 comments on commit 7b9feb6

Please sign in to comment.