Changeset View
Changeset View
Standalone View
Standalone View
src/applications/feed/story/PhabricatorFeedStory.php
| Show First 20 Lines • Show All 42 Lines • ▼ Show 20 Lines | public static function loadAllFromRows(array $rows, PhabricatorUser $viewer) { | ||||
| $data = id(new PhabricatorFeedStoryData())->loadAllFromArray($rows); | $data = id(new PhabricatorFeedStoryData())->loadAllFromArray($rows); | ||||
| foreach ($data as $story_data) { | foreach ($data as $story_data) { | ||||
| $class = $story_data->getStoryType(); | $class = $story_data->getStoryType(); | ||||
| try { | try { | ||||
| $ok = | $ok = | ||||
| class_exists($class) && | class_exists($class) && | ||||
| is_subclass_of($class, 'PhabricatorFeedStory'); | is_subclass_of($class, __CLASS__); | ||||
| } catch (PhutilMissingSymbolException $ex) { | } catch (PhutilMissingSymbolException $ex) { | ||||
| $ok = false; | $ok = false; | ||||
| } | } | ||||
| // If the story type isn't a valid class or isn't a subclass of | // If the story type isn't a valid class or isn't a subclass of | ||||
| // PhabricatorFeedStory, decline to load it. | // PhabricatorFeedStory, decline to load it. | ||||
| if (!$ok) { | if (!$ok) { | ||||
| continue; | continue; | ||||
| ▲ Show 20 Lines • Show All 473 Lines • Show Last 20 Lines | |||||