Topic A has 7 posts. Post 7 quotes a part of the text from Post 6.
We split to new topic (B) from Post 3 and below, because this part is off-topic.
In the new topic (B), Post 4 (Post 7 from topic A) shows the quote to a deleted Post 6 from topic A showing a trash can icon within the quote block, while I think it should show the quote of post 3 (post 6 in topic A) in the new topic.
Yes, I can reproduce that here: https://try.discourse.org/t/topic-splitting-test-part-two/1388. When I try to expand quote in the last post in the split topic, a request is made to the topic the posts were split from. This returns a 404 response and causes the trash can icon to be displayed.
This is a best-effort fix which tries to replace constructs such as post:{old post number}, topic:{old topic ID} using data from quoted_posts and moved_posts, without knowing if it is indeed a part of the [quote] tag.