Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15273341
D16451.id39569.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
3 KB
Referenced Files
None
Subscribers
None
D16451.id39569.diff
View Options
diff --git a/src/applications/people/controller/PhabricatorPeopleApproveController.php b/src/applications/people/controller/PhabricatorPeopleApproveController.php
--- a/src/applications/people/controller/PhabricatorPeopleApproveController.php
+++ b/src/applications/people/controller/PhabricatorPeopleApproveController.php
@@ -3,20 +3,12 @@
final class PhabricatorPeopleApproveController
extends PhabricatorPeopleController {
- private $id;
-
- public function willProcessRequest(array $data) {
- $this->id = idx($data, 'id');
- }
-
- public function processRequest() {
-
- $request = $this->getRequest();
- $admin = $request->getUser();
+ public function handleRequest(AphrontRequest $request) {
+ $viewer = $request->getViewer();
$user = id(new PhabricatorPeopleQuery())
- ->setViewer($admin)
- ->withIDs(array($this->id))
+ ->setViewer($viewer)
+ ->withIDs(array($request->getURIData('id')))
->executeOne();
if (!$user) {
return new Aphront404Response();
@@ -26,7 +18,7 @@
if ($request->isFormPost()) {
id(new PhabricatorUserEditor())
- ->setActor($admin)
+ ->setActor($viewer)
->approveUser($user, true);
$title = pht(
@@ -39,12 +31,12 @@
'Your Phabricator account (%s) has been approved by %s. You can '.
'login here:',
$user->getUsername(),
- $admin->getUsername()),
+ $viewer->getUsername()),
PhabricatorEnv::getProductionURI('/'));
$mail = id(new PhabricatorMetaMTAMail())
->addTos(array($user->getPHID()))
- ->addCCs(array($admin->getPHID()))
+ ->addCCs(array($viewer->getPHID()))
->setSubject('[Phabricator] '.$title)
->setForceDelivery(true)
->setBody($body)
diff --git a/src/applications/people/controller/PhabricatorPeopleListController.php b/src/applications/people/controller/PhabricatorPeopleListController.php
--- a/src/applications/people/controller/PhabricatorPeopleListController.php
+++ b/src/applications/people/controller/PhabricatorPeopleListController.php
@@ -3,8 +3,6 @@
final class PhabricatorPeopleListController
extends PhabricatorPeopleController {
- private $key;
-
public function shouldAllowPublic() {
return true;
}
@@ -13,16 +11,12 @@
return false;
}
- public function willProcessRequest(array $data) {
- $this->key = idx($data, 'key');
- }
-
- public function processRequest() {
+ public function handleRequest(AphrontRequest $request) {
$this->requireApplicationCapability(
PeopleBrowseUserDirectoryCapability::CAPABILITY);
$controller = id(new PhabricatorApplicationSearchController())
- ->setQueryKey($this->key)
+ ->setQueryKey($request->getURIData('key'))
->setSearchEngine(new PhabricatorPeopleSearchEngine())
->setNavigation($this->buildSideNavView());
diff --git a/src/applications/people/controller/PhabricatorPeopleLogsController.php b/src/applications/people/controller/PhabricatorPeopleLogsController.php
--- a/src/applications/people/controller/PhabricatorPeopleLogsController.php
+++ b/src/applications/people/controller/PhabricatorPeopleLogsController.php
@@ -3,15 +3,9 @@
final class PhabricatorPeopleLogsController
extends PhabricatorPeopleController {
- private $queryKey;
-
- public function willProcessRequest(array $data) {
- $this->queryKey = idx($data, 'queryKey');
- }
-
- public function processRequest() {
- $controller = id(new PhabricatorApplicationSearchController())
- ->setQueryKey($this->queryKey)
+ public function handleRequest(AphrontRequest $request) {
+ $controller = id(new PhabricatorApplicationSearchController())
+ ->setQueryKey($request->getURIData('queryKey'))
->setSearchEngine(new PhabricatorPeopleLogSearchEngine())
->setNavigation($this->buildSideNavView());
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Mar 1, 2:20 PM (7 h, 8 m)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7215629
Default Alt Text
D16451.id39569.diff (3 KB)
Attached To
Mode
D16451: Update People for handleRequest
Attached
Detach File
Event Timeline
Log In to Comment