diff options
| author | fisharebest <fisharebest@gmail.com> | 2011-12-05 22:33:32 +0000 |
|---|---|---|
| committer | fisharebest <fisharebest@gmail.com> | 2011-12-05 22:33:32 +0000 |
| commit | f7f9340cef76ed6a389cdf4a2136d87d429fd4c4 (patch) | |
| tree | de8a827bc0dc9d16b247a4bb3c45b8afcc80bacf /library/WT/Controller/Pedigree.php | |
| parent | 939612025a24f494f324b6f5091fe36e1a9c6dd7 (diff) | |
| download | webtrees-f7f9340cef76ed6a389cdf4a2136d87d429fd4c4.tar.gz webtrees-f7f9340cef76ed6a389cdf4a2136d87d429fd4c4.tar.bz2 webtrees-f7f9340cef76ed6a389cdf4a2136d87d429fd4c4.zip | |
#900273 - Default person in charts
Diffstat (limited to 'library/WT/Controller/Pedigree.php')
| -rw-r--r-- | library/WT/Controller/Pedigree.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/library/WT/Controller/Pedigree.php b/library/WT/Controller/Pedigree.php index 34269437fb..3cddb105e8 100644 --- a/library/WT/Controller/Pedigree.php +++ b/library/WT/Controller/Pedigree.php @@ -83,11 +83,11 @@ class WT_Controller_Pedigree extends WT_Controller_Chart { $show_full = $this->show_full; $talloffset = $this->talloffset; - // Validate parameters - $this->rootid=check_rootid($this->rootid); - $this->rootPerson = WT_Person::getInstance($this->rootid); - if (is_null($this->rootPerson)) $this->rootPerson = new WT_Person(''); + if (!$this->rootPerson) { + $this->rootPerson=$this->getSignificantIndividual(); + $this->rootid=$this->rootPerson->getXref(); + } $this->name = $this->rootPerson->getFullName(); $this->addname = $this->rootPerson->getAddName(); |
