1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-30 18:52:42 +01:00
phorge-phorge/src/applications/search/storage
epriestley 9f5e6bee90 Make the default behavior of getApplicationTransactionCommentObject() "return null" instead of "throw"
Summary:
Depends on D20115. See <https://discourse.phabricator-community.org/t/transaction-search-endpoint-does-not-work-on-differential-diffs/2369/>.

Currently, `getApplicationTransactionCommentObject()` throws by default. Subclasses must override it to `return null` to indicate that they don't support comments.

This is silly, and leads to a bunch of code that does a `try / catch` around it, and at least some code (here, `transaction.search`) which doesn't `try / catch` and gets the wrong behavior as a result.

Just make it `return null` by default, meaning "no support for comments". Then remove the `try / catch` stuff and all the `return null` implementations.

Test Plan:
  - Grepped for `getApplicationTransactionCommentObject()`, fixed each callsite / definition.
  - Called `transaction.search` on a diff with transactions (i.e., not a sourced-from-commit diff).

Reviewers: amckinley

Reviewed By: amckinley

Subscribers: jbrownEP

Differential Revision: https://secure.phabricator.com/D20121
2019-02-07 14:56:38 -08:00
..
document Use stemming in the MySQL fulltext search engine 2016-11-25 15:30:50 -08:00
PhabricatorNamedQuery.php Separate saved queries in applications into "personal" and "global" queries 2017-08-24 15:24:34 -07:00
PhabricatorNamedQueryConfig.php Make the default ApplicationSearch query explicit, not just the first item in the list 2017-08-24 15:21:00 -07:00
PhabricatorProfileMenuItemConfiguration.php Remove "getApplicationTransactionObject()" from ApplicationTransactionInterface 2018-12-20 15:16:19 -08:00
PhabricatorProfileMenuItemConfigurationTransaction.php Make the default behavior of getApplicationTransactionCommentObject() "return null" instead of "throw" 2019-02-07 14:56:38 -08:00
PhabricatorSavedQuery.php Fix a bug where "View as Query" could replace a saved query row by ID, causing workboard 404s 2018-11-01 05:44:49 -07:00
PhabricatorSearchDAO.php Remove @group annotations 2014-07-10 08:12:48 +10:00
PhabricatorSearchIndexVersion.php Allow index extensions to skip indexing if the object has not changed 2015-12-21 17:27:14 -08:00
PhabricatorSearchSchemaSpec.php Rename "ProfilePanelConfiguration" to "ProfileMenuItemConfiguration" 2016-12-11 11:44:22 -08:00