Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2682464
D25826.1734660434.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
D25826.1734660434.diff
View Options
diff --git a/src/applications/diffusion/controller/DiffusionServeController.php b/src/applications/diffusion/controller/DiffusionServeController.php
--- a/src/applications/diffusion/controller/DiffusionServeController.php
+++ b/src/applications/diffusion/controller/DiffusionServeController.php
@@ -492,6 +492,9 @@
return $result;
}
+ /**
+ * @return bool
+ */
private function isReadOnlyRequest(
PhabricatorRepository $repository) {
$request = $this->getRequest();
@@ -652,6 +655,9 @@
return id(new DiffusionGitResponse())->setGitData($stdout);
}
+ /**
+ * @return string
+ */
private function getRequestDirectoryPath(PhabricatorRepository $repository) {
$request = $this->getRequest();
$request_path = $request->getRequestURI()->getPath();
@@ -659,7 +665,11 @@
$info = PhabricatorRepository::parseRepositoryServicePath(
$request_path,
$repository->getVersionControlSystem());
- $base_path = $info['path'];
+ if ($info) {
+ $base_path = $info['path'];
+ } else {
+ $base_path = '';
+ }
// For Git repositories, strip an optional directory component if it
// isn't the name of a known Git resource. This allows users to clone
diff --git a/src/applications/repository/storage/PhabricatorRepository.php b/src/applications/repository/storage/PhabricatorRepository.php
--- a/src/applications/repository/storage/PhabricatorRepository.php
+++ b/src/applications/repository/storage/PhabricatorRepository.php
@@ -604,6 +604,9 @@
return "/R{$id}:{$identifier}";
}
+ /**
+ * @return array|null
+ */
public static function parseRepositoryServicePath($request_path, $vcs) {
$is_git = ($vcs == PhabricatorRepositoryType::REPOSITORY_TYPE_GIT);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Dec 20, 02:07 (18 h, 13 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1016369
Default Alt Text
D25826.1734660434.diff (1 KB)
Attached To
Mode
D25826: Avoid RuntimeException passing bogus "service" parameter to Diffusion commit view
Attached
Detach File
Event Timeline
Log In to Comment