diff options
| author | Greg Roach <fisharebest@gmail.com> | 2015-06-01 17:21:14 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@gmail.com> | 2015-06-01 17:21:14 +0100 |
| commit | 06ef8e025079fd29d56aff675f7e1fed723f571f (patch) | |
| tree | 7cf1209979c92616254db802962f1127635b169f /app/Individual.php | |
| parent | 391f48442a5be4aa3de1ff39b61447f8dd806b8d (diff) | |
| download | webtrees-06ef8e025079fd29d56aff675f7e1fed723f571f.tar.gz webtrees-06ef8e025079fd29d56aff675f7e1fed723f571f.tar.bz2 webtrees-06ef8e025079fd29d56aff675f7e1fed723f571f.zip | |
Prefer self/static to class name
Diffstat (limited to 'app/Individual.php')
| -rw-r--r-- | app/Individual.php | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/app/Individual.php b/app/Individual.php index 43762db667..0949ab721a 100644 --- a/app/Individual.php +++ b/app/Individual.php @@ -35,27 +35,6 @@ class Individual extends GedcomRecord { private $_getEstimatedDeathDate; /** - * Get an instance of an individual object. For single records, - * we just receive the XREF. For bulk records (such as lists - * and search results) we can receive the GEDCOM data as well. - * - * @param string $xref - * @param Tree $tree - * @param string|null $gedcom - * - * @return Individual|null - */ - public static function getInstance($xref, Tree $tree, $gedcom = null) { - $record = parent::getInstance($xref, $tree, $gedcom); - - if ($record instanceof Individual) { - return $record; - } else { - return null; - } - } - - /** * Sometimes, we'll know in advance that we need to load a set of records. * Typically when we load families and their members. * @@ -162,7 +141,7 @@ class Individual extends GedcomRecord { private static function isRelated(Individual $target, $distance) { static $cache = null; - $user_individual = Individual::getInstance($target->tree->getUserPreference(Auth::user(), 'gedcomid'), $target->tree); + $user_individual = self::getInstance($target->tree->getUserPreference(Auth::user(), 'gedcomid'), $target->tree); if ($user_individual) { if (!$cache) { $cache = array( |
