diff --git a/src/__phutil_library_map__.php b/src/__phutil_library_map__.php index 6fd8ff642a..25bd89cbb4 100644 --- a/src/__phutil_library_map__.php +++ b/src/__phutil_library_map__.php @@ -422,7 +422,6 @@ phutil_register_library_map(array( 'ManiphestTask' => 'applications/maniphest/storage/task', 'ManiphestTaskAuxiliaryStorage' => 'applications/maniphest/storage/auxiliary', 'ManiphestTaskDescriptionChangeController' => 'applications/maniphest/controller/descriptionchange', - 'ManiphestTaskDescriptionDiffController' => 'applications/maniphest/controller/descriptiondiff', 'ManiphestTaskDescriptionPreviewController' => 'applications/maniphest/controller/descriptionpreview', 'ManiphestTaskDetailController' => 'applications/maniphest/controller/taskdetail', 'ManiphestTaskEditController' => 'applications/maniphest/controller/taskedit', @@ -1232,7 +1231,6 @@ phutil_register_library_map(array( 'ManiphestTask' => 'ManiphestDAO', 'ManiphestTaskAuxiliaryStorage' => 'ManiphestDAO', 'ManiphestTaskDescriptionChangeController' => 'ManiphestController', - 'ManiphestTaskDescriptionDiffController' => 'ManiphestTaskDescriptionChangeController', 'ManiphestTaskDescriptionPreviewController' => 'ManiphestController', 'ManiphestTaskDetailController' => 'ManiphestController', 'ManiphestTaskEditController' => 'ManiphestController', @@ -1522,7 +1520,7 @@ phutil_register_library_map(array( 'PhabricatorRepositorySymbol' => 'PhabricatorRepositoryDAO', 'PhabricatorRepositoryTestCase' => 'PhabricatorTestCase', 'PhabricatorS3FileStorageEngine' => 'PhabricatorFileStorageEngine', - 'PhabricatorSearchAttachController' => 'PhabricatorSearchController', + 'PhabricatorSearchAttachController' => 'PhabricatorSearchBaseController', 'PhabricatorSearchBaseController' => 'PhabricatorController', 'PhabricatorSearchCommitIndexer' => 'PhabricatorSearchDocumentIndexer', 'PhabricatorSearchController' => 'PhabricatorSearchBaseController', @@ -1537,7 +1535,7 @@ phutil_register_library_map(array( 'PhabricatorSearchPhrictionIndexer' => 'PhabricatorSearchDocumentIndexer', 'PhabricatorSearchQuery' => 'PhabricatorSearchDAO', 'PhabricatorSearchResultView' => 'AphrontView', - 'PhabricatorSearchSelectController' => 'PhabricatorSearchController', + 'PhabricatorSearchSelectController' => 'PhabricatorSearchBaseController', 'PhabricatorSearchUserIndexer' => 'PhabricatorSearchDocumentIndexer', 'PhabricatorSlowvoteChoice' => 'PhabricatorSlowvoteDAO', 'PhabricatorSlowvoteComment' => 'PhabricatorSlowvoteDAO', diff --git a/src/aphront/console/controller/DarkConsoleController.php b/src/aphront/console/controller/DarkConsoleController.php index 92bc1be753..9b0aebe7df 100644 --- a/src/aphront/console/controller/DarkConsoleController.php +++ b/src/aphront/console/controller/DarkConsoleController.php @@ -1,7 +1,7 @@ array( 'create/' => 'ManiphestTaskEditController', 'edit/(?P\d+)/' => 'ManiphestTaskEditController', - 'descriptionchange/(?P\d+)/' => + 'descriptionchange/(?:(?P\d+)/)?' => 'ManiphestTaskDescriptionChangeController', - 'descriptiondiff/' => - 'ManiphestTaskDescriptionDiffController', 'descriptionpreview/' => 'ManiphestTaskDescriptionPreviewController', ), diff --git a/src/applications/auth/controller/disabled/PhabricatorDisabledUserController.php b/src/applications/auth/controller/disabled/PhabricatorDisabledUserController.php index e689876b49..02008b7b28 100644 --- a/src/applications/auth/controller/disabled/PhabricatorDisabledUserController.php +++ b/src/applications/auth/controller/disabled/PhabricatorDisabledUserController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/auth/controller/unlink/PhabricatorOAuthUnlinkController.php b/src/applications/auth/controller/unlink/PhabricatorOAuthUnlinkController.php index d94c9af343..6d7de0192f 100644 --- a/src/applications/auth/controller/unlink/PhabricatorOAuthUnlinkController.php +++ b/src/applications/auth/controller/unlink/PhabricatorOAuthUnlinkController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorOAuthUnlinkController extends PhabricatorAuthController { +final class PhabricatorOAuthUnlinkController extends PhabricatorAuthController { private $provider; diff --git a/src/applications/auth/controller/validate/PhabricatorLoginValidateController.php b/src/applications/auth/controller/validate/PhabricatorLoginValidateController.php index 838dbf96b6..e8b3de5045 100644 --- a/src/applications/auth/controller/validate/PhabricatorLoginValidateController.php +++ b/src/applications/auth/controller/validate/PhabricatorLoginValidateController.php @@ -16,7 +16,8 @@ * limitations under the License. */ -class PhabricatorLoginValidateController extends PhabricatorAuthController { +final class PhabricatorLoginValidateController + extends PhabricatorAuthController { public function shouldRequireLogin() { return false; diff --git a/src/applications/base/controller/404/Phabricator404Controller.php b/src/applications/base/controller/404/Phabricator404Controller.php index 591e7a3c3e..643ffdcfd6 100644 --- a/src/applications/base/controller/404/Phabricator404Controller.php +++ b/src/applications/base/controller/404/Phabricator404Controller.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/conduit/controller/token/PhabricatorConduitTokenController.php b/src/applications/conduit/controller/token/PhabricatorConduitTokenController.php index 7579e4192c..ad56c11ad5 100644 --- a/src/applications/conduit/controller/token/PhabricatorConduitTokenController.php +++ b/src/applications/conduit/controller/token/PhabricatorConduitTokenController.php @@ -19,7 +19,8 @@ /** * @group conduit */ -class PhabricatorConduitTokenController extends PhabricatorConduitController { +final class PhabricatorConduitTokenController + extends PhabricatorConduitController { public function processRequest() { diff --git a/src/applications/countdown/controller/delete/PhabricatorCountdownDeleteController.php b/src/applications/countdown/controller/delete/PhabricatorCountdownDeleteController.php index 97e6963609..6798c4f819 100644 --- a/src/applications/countdown/controller/delete/PhabricatorCountdownDeleteController.php +++ b/src/applications/countdown/controller/delete/PhabricatorCountdownDeleteController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorCountdownDeleteController +final class PhabricatorCountdownDeleteController extends PhabricatorCountdownController { public function willProcessRequest(array $data) { diff --git a/src/applications/countdown/controller/edit/PhabricatorCountdownEditController.php b/src/applications/countdown/controller/edit/PhabricatorCountdownEditController.php index 854e395aae..5853b912be 100644 --- a/src/applications/countdown/controller/edit/PhabricatorCountdownEditController.php +++ b/src/applications/countdown/controller/edit/PhabricatorCountdownEditController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorCountdownEditController +final class PhabricatorCountdownEditController extends PhabricatorCountdownController { private $id; diff --git a/src/applications/countdown/controller/list/PhabricatorCountdownListController.php b/src/applications/countdown/controller/list/PhabricatorCountdownListController.php index 1e23fe181c..2291f8f0db 100644 --- a/src/applications/countdown/controller/list/PhabricatorCountdownListController.php +++ b/src/applications/countdown/controller/list/PhabricatorCountdownListController.php @@ -1,7 +1,7 @@ loadAllWhere( diff --git a/src/applications/daemon/controller/loglist/PhabricatorDaemonLogListController.php b/src/applications/daemon/controller/loglist/PhabricatorDaemonLogListController.php index eb69979409..feeac6e023 100644 --- a/src/applications/daemon/controller/loglist/PhabricatorDaemonLogListController.php +++ b/src/applications/daemon/controller/loglist/PhabricatorDaemonLogListController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/daemon/controller/logview/PhabricatorDaemonLogViewController.php b/src/applications/daemon/controller/logview/PhabricatorDaemonLogViewController.php index ffb95ecd9e..4482d39811 100644 --- a/src/applications/daemon/controller/logview/PhabricatorDaemonLogViewController.php +++ b/src/applications/daemon/controller/logview/PhabricatorDaemonLogViewController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/differential/controller/diffcreate/DifferentialDiffCreateController.php b/src/applications/differential/controller/diffcreate/DifferentialDiffCreateController.php index b7cd188dae..b3b91298c4 100644 --- a/src/applications/differential/controller/diffcreate/DifferentialDiffCreateController.php +++ b/src/applications/differential/controller/diffcreate/DifferentialDiffCreateController.php @@ -1,7 +1,7 @@ diffusionRequest; diff --git a/src/applications/diffusion/controller/change/DiffusionChangeController.php b/src/applications/diffusion/controller/change/DiffusionChangeController.php index 79b01e8183..862492783f 100644 --- a/src/applications/diffusion/controller/change/DiffusionChangeController.php +++ b/src/applications/diffusion/controller/change/DiffusionChangeController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class DiffusionChangeController extends DiffusionController { +final class DiffusionChangeController extends DiffusionController { public function processRequest() { $drequest = $this->diffusionRequest; diff --git a/src/applications/diffusion/controller/commit/DiffusionCommitController.php b/src/applications/diffusion/controller/commit/DiffusionCommitController.php index 858a52f51a..4b524e1674 100644 --- a/src/applications/diffusion/controller/commit/DiffusionCommitController.php +++ b/src/applications/diffusion/controller/commit/DiffusionCommitController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class DiffusionCommitController extends DiffusionController { +final class DiffusionCommitController extends DiffusionController { const CHANGES_LIMIT = 100; diff --git a/src/applications/diffusion/controller/diff/DiffusionDiffController.php b/src/applications/diffusion/controller/diff/DiffusionDiffController.php index ba5acb80ba..33eac0dd36 100644 --- a/src/applications/diffusion/controller/diff/DiffusionDiffController.php +++ b/src/applications/diffusion/controller/diff/DiffusionDiffController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/diffusion/controller/file/DiffusionBrowseFileController.php b/src/applications/diffusion/controller/file/DiffusionBrowseFileController.php index 18cd2b47b4..2b16b36683 100644 --- a/src/applications/diffusion/controller/file/DiffusionBrowseFileController.php +++ b/src/applications/diffusion/controller/file/DiffusionBrowseFileController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class DiffusionBrowseFileController extends DiffusionController { +final class DiffusionBrowseFileController extends DiffusionController { // Image types we want to display inline using tags protected $imageTypes = array( diff --git a/src/applications/diffusion/controller/history/DiffusionHistoryController.php b/src/applications/diffusion/controller/history/DiffusionHistoryController.php index 499955d03d..5cd766e4c0 100644 --- a/src/applications/diffusion/controller/history/DiffusionHistoryController.php +++ b/src/applications/diffusion/controller/history/DiffusionHistoryController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class DiffusionHistoryController extends DiffusionController { +final class DiffusionHistoryController extends DiffusionController { public function processRequest() { $drequest = $this->diffusionRequest; diff --git a/src/applications/diffusion/controller/home/DiffusionHomeController.php b/src/applications/diffusion/controller/home/DiffusionHomeController.php index a5fdc4e7b7..52f3a323e2 100644 --- a/src/applications/diffusion/controller/home/DiffusionHomeController.php +++ b/src/applications/diffusion/controller/home/DiffusionHomeController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/diffusion/controller/lastmodified/DiffusionLastModifiedController.php b/src/applications/diffusion/controller/lastmodified/DiffusionLastModifiedController.php index 1e64fd66eb..26380b6848 100644 --- a/src/applications/diffusion/controller/lastmodified/DiffusionLastModifiedController.php +++ b/src/applications/diffusion/controller/lastmodified/DiffusionLastModifiedController.php @@ -1,7 +1,7 @@ getDiffusionRequest(); diff --git a/src/applications/diffusion/controller/pathcomplete/DiffusionPathCompleteController.php b/src/applications/diffusion/controller/pathcomplete/DiffusionPathCompleteController.php index 4536a643cd..2efcbdd60f 100644 --- a/src/applications/diffusion/controller/pathcomplete/DiffusionPathCompleteController.php +++ b/src/applications/diffusion/controller/pathcomplete/DiffusionPathCompleteController.php @@ -1,7 +1,7 @@ diffusionRequest; diff --git a/src/applications/diffusion/controller/symbol/DiffusionSymbolController.php b/src/applications/diffusion/controller/symbol/DiffusionSymbolController.php index d042488cdd..c11e5965ad 100644 --- a/src/applications/diffusion/controller/symbol/DiffusionSymbolController.php +++ b/src/applications/diffusion/controller/symbol/DiffusionSymbolController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/files/controller/list/PhabricatorFileListController.php b/src/applications/files/controller/list/PhabricatorFileListController.php index 7aa7c24e10..00db73770f 100644 --- a/src/applications/files/controller/list/PhabricatorFileListController.php +++ b/src/applications/files/controller/list/PhabricatorFileListController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorFileListController extends PhabricatorFileController { +final class PhabricatorFileListController extends PhabricatorFileController { private $filter; private $showUploader; diff --git a/src/applications/files/controller/macrodelete/PhabricatorFileMacroDeleteController.php b/src/applications/files/controller/macrodelete/PhabricatorFileMacroDeleteController.php index d8d8187f89..b5f8c2e819 100644 --- a/src/applications/files/controller/macrodelete/PhabricatorFileMacroDeleteController.php +++ b/src/applications/files/controller/macrodelete/PhabricatorFileMacroDeleteController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/files/controller/proxy/PhabricatorFileProxyController.php b/src/applications/files/controller/proxy/PhabricatorFileProxyController.php index 1b29b874ff..8c449fcdc8 100644 --- a/src/applications/files/controller/proxy/PhabricatorFileProxyController.php +++ b/src/applications/files/controller/proxy/PhabricatorFileProxyController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorFileProxyController extends PhabricatorFileController { +final class PhabricatorFileProxyController extends PhabricatorFileController { private $uri; diff --git a/src/applications/files/controller/transform/PhabricatorFileTransformController.php b/src/applications/files/controller/transform/PhabricatorFileTransformController.php index dca8e11598..06475cb8c0 100644 --- a/src/applications/files/controller/transform/PhabricatorFileTransformController.php +++ b/src/applications/files/controller/transform/PhabricatorFileTransformController.php @@ -16,7 +16,8 @@ * limitations under the License. */ -class PhabricatorFileTransformController extends PhabricatorFileController { +final class PhabricatorFileTransformController + extends PhabricatorFileController { private $transform; private $phid; diff --git a/src/applications/files/controller/upload/PhabricatorFileUploadController.php b/src/applications/files/controller/upload/PhabricatorFileUploadController.php index fed5387517..fd367f9bd0 100644 --- a/src/applications/files/controller/upload/PhabricatorFileUploadController.php +++ b/src/applications/files/controller/upload/PhabricatorFileUploadController.php @@ -1,7 +1,7 @@ setTransactionID($data['id']); + $this->setTransactionID(idx($data, 'id')); } public function processRequest() { $request = $this->getRequest(); $user = $request->getUser(); + if (!$this->getTransactionID()) { + $this->setTransactionID($this->getRequest()->getStr('ref')); + } + $transaction_id = $this->getTransactionID(); $transaction = id(new ManiphestTransaction())->load($transaction_id); if (!$transaction) { diff --git a/src/applications/maniphest/controller/descriptiondiff/ManiphestTaskDescriptionDiffController.php b/src/applications/maniphest/controller/descriptiondiff/ManiphestTaskDescriptionDiffController.php deleted file mode 100644 index e9e00eddd4..0000000000 --- a/src/applications/maniphest/controller/descriptiondiff/ManiphestTaskDescriptionDiffController.php +++ /dev/null @@ -1,29 +0,0 @@ -getRequest()->getStr('ref'); - $this->setTransactionID($ref); - } -} diff --git a/src/applications/maniphest/controller/descriptiondiff/__init__.php b/src/applications/maniphest/controller/descriptiondiff/__init__.php deleted file mode 100644 index 7e1ba1bbda..0000000000 --- a/src/applications/maniphest/controller/descriptiondiff/__init__.php +++ /dev/null @@ -1,12 +0,0 @@ -getRequest(); diff --git a/src/applications/maniphest/view/transactionlist/ManiphestTransactionListView.php b/src/applications/maniphest/view/transactionlist/ManiphestTransactionListView.php index 66a912d131..417d94f3a6 100644 --- a/src/applications/maniphest/view/transactionlist/ManiphestTransactionListView.php +++ b/src/applications/maniphest/view/transactionlist/ManiphestTransactionListView.php @@ -96,7 +96,7 @@ class ManiphestTransactionListView extends ManiphestView { require_celerity_resource('syntax-highlighting-css'); $whitespace_mode = DifferentialChangesetParser::WHITESPACE_SHOW_ALL; Javelin::initBehavior('differential-show-more', array( - 'uri' => '/maniphest/task/descriptiondiff/', + 'uri' => '/maniphest/task/descriptionchange/', 'whitespace' => $whitespace_mode, )); } diff --git a/src/applications/metamta/controller/list/PhabricatorMetaMTAListController.php b/src/applications/metamta/controller/list/PhabricatorMetaMTAListController.php index 325077d5f1..459ebc08db 100644 --- a/src/applications/metamta/controller/list/PhabricatorMetaMTAListController.php +++ b/src/applications/metamta/controller/list/PhabricatorMetaMTAListController.php @@ -16,7 +16,8 @@ * limitations under the License. */ -class PhabricatorMetaMTAListController extends PhabricatorMetaMTAController { +final class PhabricatorMetaMTAListController + extends PhabricatorMetaMTAController { public function processRequest() { // Get a page of mails together with pager. diff --git a/src/applications/metamta/controller/mailinglistedit/PhabricatorMetaMTAMailingListEditController.php b/src/applications/metamta/controller/mailinglistedit/PhabricatorMetaMTAMailingListEditController.php index 3d40143bf5..b90dc60a20 100644 --- a/src/applications/metamta/controller/mailinglistedit/PhabricatorMetaMTAMailingListEditController.php +++ b/src/applications/metamta/controller/mailinglistedit/PhabricatorMetaMTAMailingListEditController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorMetaMTAMailingListEditController +final class PhabricatorMetaMTAMailingListEditController extends PhabricatorMetaMTAController { private $id; diff --git a/src/applications/metamta/controller/mailinglists/PhabricatorMetaMTAMailingListsController.php b/src/applications/metamta/controller/mailinglists/PhabricatorMetaMTAMailingListsController.php index 858d6fb38b..6dbb57117b 100644 --- a/src/applications/metamta/controller/mailinglists/PhabricatorMetaMTAMailingListsController.php +++ b/src/applications/metamta/controller/mailinglists/PhabricatorMetaMTAMailingListsController.php @@ -16,7 +16,7 @@ * limitations under the License. */ -class PhabricatorMetaMTAMailingListsController +final class PhabricatorMetaMTAMailingListsController extends PhabricatorMetaMTAController { public function processRequest() { diff --git a/src/applications/metamta/controller/receive/PhabricatorMetaMTAReceiveController.php b/src/applications/metamta/controller/receive/PhabricatorMetaMTAReceiveController.php index 7fef2f7907..13e26ca51d 100644 --- a/src/applications/metamta/controller/receive/PhabricatorMetaMTAReceiveController.php +++ b/src/applications/metamta/controller/receive/PhabricatorMetaMTAReceiveController.php @@ -1,7 +1,7 @@ getRequest(); diff --git a/src/applications/people/controller/logs/PhabricatorPeopleLogsController.php b/src/applications/people/controller/logs/PhabricatorPeopleLogsController.php index 545a2ee27c..178b32fb04 100644 --- a/src/applications/people/controller/logs/PhabricatorPeopleLogsController.php +++ b/src/applications/people/controller/logs/PhabricatorPeopleLogsController.php @@ -1,7 +1,7 @@ save(); $dao->makeEphemeral(); - $this->assertException( - 'LiskEphemeralObjectException', - function() use ($dao) { - $dao->save(); - } - ); + $this->tryTestCases( + array( + $dao, + ), + array( + false, + ), + array($this, 'saveDAO')); + } + + public function saveDAO($dao) { + $dao->save(); } public function testIsolationContainment() {