From: Florian Zschocke Date: Tue, 6 Dec 2022 20:51:54 +0000 (+0100) Subject: fix: Fix incorrect text being copied by copy button on tickets page X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=60a0434ac329af040ba11ec7dedafe581a9b588e;p=gitblit.git fix: Fix incorrect text being copied by copy button on tickets page The merge step for using `pt` added the wrong text to the copy button. --- diff --git a/src/main/java/com/gitblit/wicket/pages/TicketPage.java b/src/main/java/com/gitblit/wicket/pages/TicketPage.java index d6d188df..54fdf3a3 100644 --- a/src/main/java/com/gitblit/wicket/pages/TicketPage.java +++ b/src/main/java/com/gitblit/wicket/pages/TicketPage.java @@ -1561,7 +1561,7 @@ public class TicketPage extends RepositoryPage { // pt instructions String ptStep = MessageFormat.format("pt pull {0,number,0}", ticket.number); cmd.add(new Label("ptMergeStep", ptStep)); - cmd.add(createCopyFragment("ptMergeCopyStep", step1.replace("\n", " && "))); + cmd.add(createCopyFragment("ptMergeCopyStep", ptStep.replace("\n", " && "))); return cmd; }