[aur-dev] [PATCH 2/3] flag_comment.php: Hide comment for unflagged packages

Lukas Fleischer lfleischer at archlinux.org
Mon Feb 27 19:13:34 UTC 2017


Only show the comment paragraph if the package base is actually flagged
out-of-date.

Signed-off-by: Lukas Fleischer <lfleischer at archlinux.org>
---
 web/template/flag_comment.php | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/web/template/flag_comment.php b/web/template/flag_comment.php
index e8855fe..05eeacb 100644
--- a/web/template/flag_comment.php
+++ b/web/template/flag_comment.php
@@ -11,11 +11,13 @@
 				'<strong>', htmlspecialchars($pkgbase_name), '</strong>'); ?>
 		<?php endif; ?>
 	</p>
+	<?php if (isset($message['Username'])): ?>
 	<p>
 		<div class="article-content">
 			<blockquote><p><?= parse_comment($message['FlaggerComment']) ?></p></blockquote>
 		</div>
 	</p>
+	<?php endif; ?>
 	<p>
 		<form action="<?= htmlspecialchars(get_pkgbase_uri($pkgbase_name), ENT_QUOTES) ?>">
 			<input type="submit" value="<?= __("Return to Details") ?>" />
-- 
2.12.0


More information about the aur-dev mailing list