Renaming aliased wikilink within a Table breaks it

Steps to reproduce

There is an aliased wiki-link inside a table:

| Column 1 | Column 2 |
| :------- | :------- |
| [[link1]] | Example |
| [[link1\|alias of link1]] | Example |

Open note “link1” in Obsidian and rename the title to “link2” (renaming).

Did you follow the troubleshooting guide? Y

Expected result

Apply the renamed note name while preserving the escape for aliased wiki-links.

| Column 1 | Column 2 |
| :------- | :------- |
| [[link2]] | Example |
| [[link2\|alias of link1]] | Example |

Actual result

The escape for the aliased wiki-link is removed, and the table breaks as follows:

| Column 1 | Column 2 |
| :------- | :------- |
| [[link2]] | Example |
| [[link2|alias of link1]] | Example |

Environment

OS: Windows 10 22H2
Obsidian Version: 1.3.4


Additional information

3 Likes

Steps to reproduce

  1. Go to Settings > Files & Links and there enable “Automatically update internal links”
  2. Create a note and give it any name
  3. Create a second note containing a table
  4. Link to the first note within the table and give it an alias (the character “|” needs to be escaped with "")
  5. Now update the first note’s name

Expected result

The link gets updated correctly

Actual result

The link to the first note in the table of the second note gets updated (which is expected) but the escaping is lost → which means the table and the link is broken)

This can be reproduced inside one note.
Create note Rename-Test

|1|2|
:-|:-:
|[[Rename-Test#Target\|Target]]|Some data|

[[Rename-Test#Target|Target]]
# Target

Rename Rename-Test, after renaming file will look like this. Both links are still fine except missing \.

|1|2|
:-|:-:
|[[Rename-Test2#Target|Target]]|Some data|

[[Rename-Test2#Target|Target]]
# Target

After next rename, link inside table will be broken.

|1|2|
:-|:-:
|[[Rename-Test2#Target|Target]]|Some data|

[[Rename-Test3#Target|Target]]
# Target

Currently running version 1.4.14 and ran into this bug renaming a folder. I use Absolute path in vault option for links so some of my paths can be quite long and troublesome to fix.

One of the bigger problems with this bug is if you then go and update the links again (againrename a folder for example) the links in my experience wont get updated again since they’re no longer linked.