mirror of
https://github.com/Myriad-Dreamin/tinymist.git
synced 2025-08-04 10:18:16 +00:00
fix: check file paths on renaming files (#1080)
This commit is contained in:
parent
ef4714c195
commit
978e4d6f4e
1 changed files with 3 additions and 1 deletions
|
@ -212,7 +212,9 @@ impl RenameFileWorker<'_> {
|
|||
let root = LinkedNode::new(ref_src.root());
|
||||
let edits = edits.entry(uri).or_default();
|
||||
for obj in &link_info.objects {
|
||||
if !matches!(obj.target, LinkTarget::Path(..)) {
|
||||
if !matches!(&obj.target,
|
||||
LinkTarget::Path(file_id, _) if *file_id == self.def_fid
|
||||
) {
|
||||
continue;
|
||||
}
|
||||
if let Some(edit) = self.rename_resource_path(obj, &root, &ref_src) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue