File tree Expand file tree Collapse file tree 2 files changed +2
-7
lines changed
app/code/Magento/CheckoutAgreements Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ protected function getAgreementsConfig()
103103 : nl2br ($ this ->escaper ->escapeHtml ($ agreement ->getContent ())),
104104 'checkboxText ' => $ isAgreementHtmlType
105105 ? $ agreement ->getCheckboxText ()
106- : $ this ->escaper ->escapeHtml ($ agreement ->getCheckboxText ()),
106+ : nl2br ( $ this ->escaper ->escapeHtml ($ agreement ->getCheckboxText () )),
107107 'mode ' => $ agreement ->getMode (),
108108 'agreementId ' => $ agreement ->getAgreementId (),
109109 'contentHeight ' => $ agreement ->getContentHeight ()
Original file line number Diff line number Diff line change @@ -98,7 +98,7 @@ public function testGetConfigIfContentIsHtml(): void
9898 'agreements ' => [
9999 [
100100 'content ' => $ content ,
101- 'checkboxText ' => $ escapedCheckboxText ,
101+ 'checkboxText ' => $ checkboxText ,
102102 'mode ' => $ mode ,
103103 'agreementId ' => $ agreementId ,
104104 'contentHeight ' => $ contentHeight
@@ -122,11 +122,6 @@ public function testGetConfigIfContentIsHtml(): void
122122 ->with ($ searchCriteriaMock )
123123 ->willReturn ([$ agreement ]);
124124
125- $ this ->escaperMock ->expects ($ this ->once ())
126- ->method ('escapeHtml ' )
127- ->with ($ checkboxText )
128- ->willReturn ($ escapedCheckboxText );
129-
130125 $ agreement ->expects ($ this ->once ())->method ('getIsHtml ' )->willReturn (true );
131126 $ agreement ->expects ($ this ->once ())->method ('getContent ' )->willReturn ($ content );
132127 $ agreement ->expects ($ this ->once ())->method ('getCheckboxText ' )->willReturn ($ checkboxText );
You can’t perform that action at this time.
0 commit comments