提交 f4212089 编写于 作者: J Jakub Narebski 提交者: Junio C Hamano

gitweb: Harden and improve $project_filter page title

Commit 19d2d239 (gitweb: add project_filter to limit project list
to a subdirectory, 2012-01-30) added also support for displaying
$project_filter, if present, in page title.

Unfortunately it forgot to treat $project_filter as path, and escape
it using esc_path(), like it is done for $filename.

Also, it was not obvious that "$site_name - $project_filter" is about
project filtering: use "$site_name - projects in '$project_filter'".
Signed-off-by: NJakub Narebski <jnareb@gmail.com>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 abc0c9d2
......@@ -3742,7 +3742,7 @@ sub get_page_title {
unless (defined $project) {
if (defined $project_filter) {
$title .= " - " . to_utf8($project_filter);
$title .= " - projects in '" . esc_path($project_filter) . "'";
}
return $title;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册