@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Make the `PhabricatorApplication::getName()` method abstract

Summary: In D10027, the `getName()` method was added to `PhabricatorApplication` to //allow// applications to explicitly declare their names rather than relying on the name being inferred from the name of the `PhabricatorApplication` subclass. I feel that sufficient time has passed such that we can //require// applications to explicitly declare their names.

Test Plan: N/A

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: epriestley

Differential Revision: https://secure.phabricator.com/D11119

+1 -17
+1 -17
src/applications/base/PhabricatorApplication.php
··· 28 28 29 29 /* -( Application Information )-------------------------------------------- */ 30 30 31 - 32 - /** 33 - * TODO: This should be abstract, but is not for historical reasons. 34 - */ 35 - public function getName() { 36 - phutil_deprecated( 37 - 'Automatic naming of `PhabricatorApplication` classes.', 38 - 'You should override the `getName` method.'); 39 - 40 - $match = null; 41 - $regex = '/^PhabricatorApplication([A-Z][a-zA-Z]*)$/'; 42 - if (preg_match($regex, get_class($this), $match)) { 43 - return $match[1]; 44 - } 45 - 46 - throw new PhutilMethodNotImplementedException(); 47 - } 31 + public abstract function getName(); 48 32 49 33 public function getShortDescription() { 50 34 return $this->getName().' Application';