Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14050614
D12663.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D12663.diff
View Options
diff --git a/src/applications/diffusion/conduit/DiffusionFindSymbolsConduitAPIMethod.php b/src/applications/diffusion/conduit/DiffusionFindSymbolsConduitAPIMethod.php
--- a/src/applications/diffusion/conduit/DiffusionFindSymbolsConduitAPIMethod.php
+++ b/src/applications/diffusion/conduit/DiffusionFindSymbolsConduitAPIMethod.php
@@ -13,11 +13,12 @@
protected function defineParamTypes() {
return array(
- 'name' => 'optional string',
- 'namePrefix' => 'optional string',
- 'context' => 'optional string',
- 'language' => 'optional string',
- 'type' => 'optional string',
+ 'name' => 'optional string',
+ 'namePrefix' => 'optional string',
+ 'context' => 'optional string',
+ 'language' => 'optional string',
+ 'type' => 'optional string',
+ 'repositoryPHID' => 'optional string',
);
}
@@ -31,6 +32,7 @@
$context = $request->getValue('context');
$language = $request->getValue('language');
$type = $request->getValue('type');
+ $repository = $request->getValue('repositoryPHID');
$query = id(new DiffusionSymbolQuery())
->setViewer($request->getUser());
@@ -49,6 +51,9 @@
if ($type !== null) {
$query->setType($type);
}
+ if ($repository !== null) {
+ $query->withRepositoryPHIDs(array($repository));
+ }
$query->needPaths(true);
$query->needRepositories(true);
@@ -64,13 +69,14 @@
}
$response[] = array(
- 'name' => $result->getSymbolName(),
- 'context' => $result->getSymbolContext(),
- 'type' => $result->getSymbolType(),
- 'language' => $result->getSymbolLanguage(),
- 'path' => $result->getPath(),
- 'line' => $result->getLineNumber(),
- 'uri' => $uri,
+ 'name' => $result->getSymbolName(),
+ 'context' => $result->getSymbolContext(),
+ 'type' => $result->getSymbolType(),
+ 'language' => $result->getSymbolLanguage(),
+ 'path' => $result->getPath(),
+ 'line' => $result->getLineNumber(),
+ 'uri' => $uri,
+ 'repositoryPHID' => $result->getRepository()->getPHID(),
);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 15, 7:46 PM (3 d, 11 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6732745
Default Alt Text
D12663.diff (2 KB)
Attached To
Mode
D12663: Add repository parameter to `diffusion.findsymbols` method
Attached
Detach File
Event Timeline
Log In to Comment