Skip to content

Commit

Permalink
Use normal (non-destructive) Append() for generating reference links
Browse files Browse the repository at this point in the history
  • Loading branch information
sideshowbarker committed Aug 9, 2023
1 parent abe0b17 commit 9226f89
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/wattsi.pas
Original file line number Diff line number Diff line change
Expand Up @@ -1588,15 +1588,13 @@ TCrossReferences = record

NewLink := ConstructHTMLElement(eA);
Scratch := Default(Rope);
ExtractedData := Element.TextContent.ExtractAll();
Scratch.Append('#refs');
Scratch.AppendDestructively(ExtractedData);
Scratch.Append(ReferenceName);
NewLink.SetAttributeDestructively('href', Scratch);

Scratch := Default(Rope);
ExtractedData := Element.TextContent.ExtractAll();
Scratch.Append('[');
Scratch.AppendDestructively(ExtractedData);
Scratch.Append(ReferenceName);
Scratch.Append(']');
NewLink.AppendChild(TText.CreateDestructively(Scratch));

Expand Down

0 comments on commit 9226f89

Please sign in to comment.