Differential D16066 Diff 38658 src/applications/conduit/controller/PhabricatorConduitAPIController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/conduit/controller/PhabricatorConduitAPIController.php
| Show First 20 Lines • Show All 481 Lines • ▼ Show 20 Lines | private function validateAuthenticatedUser( | ||||
| if (!$user->canEstablishAPISessions()) { | if (!$user->canEstablishAPISessions()) { | ||||
| return array( | return array( | ||||
| 'ERR-INVALID-AUTH', | 'ERR-INVALID-AUTH', | ||||
| pht('User account is not permitted to use the API.'), | pht('User account is not permitted to use the API.'), | ||||
| ); | ); | ||||
| } | } | ||||
| $request->setUser($user); | $request->setUser($user); | ||||
| id(new PhabricatorAuthSessionEngine()) | |||||
| ->willServeRequestForUser($user); | |||||
| return null; | return null; | ||||
| } | } | ||||
| private function buildHumanReadableResponse( | private function buildHumanReadableResponse( | ||||
| $method, | $method, | ||||
| ConduitAPIRequest $request = null, | ConduitAPIRequest $request = null, | ||||
| $result = null, | $result = null, | ||||
| ConduitAPIMethod $method_implementation = null) { | ConduitAPIMethod $method_implementation = null) { | ||||
| ▲ Show 20 Lines • Show All 206 Lines • Show Last 20 Lines | |||||