Skip to content

Commit 79ede90

Browse files
authored
[BUGFIX] Compare project_issues correctly (#675)
1 parent afe1d87 commit 79ede90

File tree

7 files changed

+28
-8
lines changed

7 files changed

+28
-8
lines changed

packages/typo3-docs-theme/src/Twig/TwigExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ public function getReportIssueLink(array $context): string
296296
$reportButton = $this->themeSettings->getSettings('project_issues');
297297
$reportButton = rtrim($reportButton, '/');
298298

299-
if (str_starts_with($reportButton, '')) {
299+
if ($reportButton === '') {
300300
return '';
301301
}
302302
if (str_starts_with($reportButton, 'https://forge.typo3.org/')) {

tests/Integration/tests-full/changelog/expected/Changelog/12.0/Breaking-87616-RemovedHookForAlteringPageLinks.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,11 @@
134134
<li class="breadcrumb-item"><a href="Index.html">12.0 Changes</a></li>
135135
<li aria-current="page" class="breadcrumb-item active">Breaking: #87616 - Removed hook for altering page links</li>
136136
</ol>
137-
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="../../_sources/Changelog/12.0/Breaking-87616-RemovedHookForAlteringPageLinks.rst.txt" rel="nofollow noopener" target="_blank">
137+
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="https://forge.typo3.org/projects/typo3cms-core/issues/new?issue[category_id]=1004&amp;issue[subject]=Problem+on+https%3A%2F%2Fextensions.typo3.org%2Fextension%2Fcore%2F%2FChangelog%2F12.0%2FBreaking-87616-RemovedHookForAlteringPageLinks.html&amp;issue[custom_field_values][4]=main" id="btnReportIssue" rel="nofollow noopener" target="_blank">
138+
<span class="btn-icon"><i class="fas fa-bug"></i></span>
139+
<span class="btn-text">Report issue</span>
140+
</a>
141+
<a class="btn btn-sm btn-light" href="../../_sources/Changelog/12.0/Breaking-87616-RemovedHookForAlteringPageLinks.rst.txt" rel="nofollow noopener" target="_blank">
138142
<span class="btn-icon"><span class="fas fa-code"></span></span>
139143
<span class="btn-text">View source</span>
140144
</a>

tests/Integration/tests-full/changelog/expected/Changelog/12.0/Index.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,11 @@
134134
<li class="breadcrumb-item"><a href="../../Changelog-12.html">ChangeLog v12</a></li>
135135
<li aria-current="page" class="breadcrumb-item active">12.0 Changes</li>
136136
</ol>
137-
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="../../_sources/Changelog/12.0/Index.rst.txt" rel="nofollow noopener" target="_blank">
137+
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="https://forge.typo3.org/projects/typo3cms-core/issues/new?issue[category_id]=1004&amp;issue[subject]=Problem+on+https%3A%2F%2Fextensions.typo3.org%2Fextension%2Fcore%2F%2FChangelog%2F12.0%2FIndex.html&amp;issue[custom_field_values][4]=main" id="btnReportIssue" rel="nofollow noopener" target="_blank">
138+
<span class="btn-icon"><i class="fas fa-bug"></i></span>
139+
<span class="btn-text">Report issue</span>
140+
</a>
141+
<a class="btn btn-sm btn-light" href="../../_sources/Changelog/12.0/Index.rst.txt" rel="nofollow noopener" target="_blank">
138142
<span class="btn-icon"><span class="fas fa-code"></span></span>
139143
<span class="btn-text">View source</span>
140144
</a>

tests/Integration/tests-full/changelog/expected/Index.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,11 @@
130130
<ol class="breadcrumb">
131131
<li aria-current="page" class="breadcrumb-item active">TYPO3 Core</li>
132132
</ol>
133-
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="_sources/Index.rst.txt" rel="nofollow noopener" target="_blank">
133+
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="https://forge.typo3.org/projects/typo3cms-core/issues/new?issue[category_id]=1004&amp;issue[subject]=Problem+on+https%3A%2F%2Fextensions.typo3.org%2Fextension%2Fcore%2F%2FIndex.html&amp;issue[custom_field_values][4]=main" id="btnReportIssue" rel="nofollow noopener" target="_blank">
134+
<span class="btn-icon"><i class="fas fa-bug"></i></span>
135+
<span class="btn-text">Report issue</span>
136+
</a>
137+
<a class="btn btn-sm btn-light" href="_sources/Index.rst.txt" rel="nofollow noopener" target="_blank">
134138
<span class="btn-icon"><span class="fas fa-code"></span></span>
135139
<span class="btn-text">View source</span>
136140
</a>

tests/Integration/tests-full/changelog/expected/Sitemap.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,11 @@
132132
<li class="breadcrumb-item"><a href="Index.html">TYPO3 Core</a></li>
133133
<li aria-current="page" class="breadcrumb-item active">Sitemap</li>
134134
</ol>
135-
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="_sources/Sitemap.rst.txt" rel="nofollow noopener" target="_blank">
135+
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="https://forge.typo3.org/projects/typo3cms-core/issues/new?issue[category_id]=1004&amp;issue[subject]=Problem+on+https%3A%2F%2Fextensions.typo3.org%2Fextension%2Fcore%2F%2FSitemap.html&amp;issue[custom_field_values][4]=main" id="btnReportIssue" rel="nofollow noopener" target="_blank">
136+
<span class="btn-icon"><i class="fas fa-bug"></i></span>
137+
<span class="btn-text">Report issue</span>
138+
</a>
139+
<a class="btn btn-sm btn-light" href="_sources/Sitemap.rst.txt" rel="nofollow noopener" target="_blank">
136140
<span class="btn-icon"><span class="fas fa-code"></span></span>
137141
<span class="btn-text">View source</span>
138142
</a>

tests/Integration/tests-full/report-issue/project-issue-github/expected/index.html

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,11 @@
105105
<ol class="breadcrumb">
106106
<li aria-current="page" class="breadcrumb-item active">Document Title</li>
107107
</ol>
108-
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="_sources/index.rst.txt" rel="nofollow noopener" target="_blank">
108+
<div class="breadcrumb-additions"> <a class="btn btn-sm btn-light" href="https://github.com/TYPO3-Documentation/TYPO3CMS-Reference-CoreApi/issues/new/choose?title=Problem+on+%2Findex.html" id="btnReportIssue" rel="nofollow noopener" target="_blank">
109+
<span class="btn-icon"><i class="fas fa-bug"></i></span>
110+
<span class="btn-text">Report issue</span>
111+
</a>
112+
<a class="btn btn-sm btn-light" href="_sources/index.rst.txt" rel="nofollow noopener" target="_blank">
109113
<span class="btn-icon"><span class="fas fa-code"></span></span>
110114
<span class="btn-text">View source</span>
111115
</a>
@@ -220,7 +224,7 @@ <h5 class="modal-title" id="generalModalLabel"></h5>
220224
<div class="frame-container">
221225
<div class="frame-inner">
222226
<ul class="footer-simplemenu">
223-
<li><a href="https://github.com/TYPO3-Documentation/render-guides/issues/new" rel="nofollow noopener" title="Issues"><span>Issues</span></a></li>
227+
<li><a href="https://github.com/TYPO3-Documentation/TYPO3CMS-Reference-CoreApi/issues" rel="nofollow noopener" title="Issues"><span>Issues</span></a></li>
224228
</ul> <div class="footer-additional">
225229
<p class="text-center">Last rendered: Jan 01, 2023 12:00</p>
226230
</div>

tests/Integration/tests-full/report-issue/project-issue-github/input/guides.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@
77

88
<project title="Lorem Ipsum"/>
99
<extension class="\T3Docs\Typo3DocsTheme\DependencyInjection\Typo3DocsThemeExtension"
10-
project-issues="https://github.com/TYPO3-Documentation/render-guides/issues/new"
10+
project-issues="https://github.com/TYPO3-Documentation/TYPO3CMS-Reference-CoreApi/issues"
1111
/>
1212
</guides>

0 commit comments

Comments
 (0)