mirror of
https://github.com/klaussilveira/gitlist.git
synced 2026-07-08 13:24:10 +02:00
ensure ref name is encoded
This commit is contained in:
@@ -199,7 +199,7 @@ class Repository
|
||||
// Otherwise, attempt to detect the ref using a list of the project's branches and tags
|
||||
$valid_refs = array_merge((array) $repository->getBranches(), (array) $repository->getTags());
|
||||
foreach ($valid_refs as $k => $v) {
|
||||
if (!preg_match("#^{$v}/#", $input)) {
|
||||
if (!preg_match(sprintf("#^%s/#", preg_quote($v, '#')), $input)) {
|
||||
unset($valid_refs[$k]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user