summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGreg Roach <fisharebest@gmail.com>2017-11-03 09:22:35 +0000
committerGreg Roach <fisharebest@gmail.com>2017-11-03 09:22:35 +0000
commit4080d558aceadf165108f8e99158ea104c7b2460 (patch)
tree24a0fbe7a3745f287d83aef5f223eff55f32e96b
parent16d0b7f74e80c16cb445079b0322702930031dc7 (diff)
downloadwebtrees-4080d558aceadf165108f8e99158ea104c7b2460.tar.gz
webtrees-4080d558aceadf165108f8e99158ea104c7b2460.tar.bz2
webtrees-4080d558aceadf165108f8e99158ea104c7b2460.zip
PHPDOC
-rw-r--r--app/Family.php7
-rw-r--r--app/GedcomRecord.php2
-rw-r--r--app/Individual.php16
-rw-r--r--app/Place.php4
4 files changed, 15 insertions, 14 deletions
diff --git a/app/Family.php b/app/Family.php
index dcbb8d0841..e4fa40bb43 100644
--- a/app/Family.php
+++ b/app/Family.php
@@ -307,12 +307,13 @@ class Family extends GedcomRecord {
/**
* Get a list of all marriage places - for the family lists.
*
- * @return array|Place[]
+ * @return Place[]
*/
public function getAllMarriagePlaces() {
foreach (explode('|', WT_EVENTS_MARR) as $event) {
- if ($array = $this->getAllEventPlaces($event)) {
- return $array;
+ $places = $this->getAllEventPlaces($event);
+ if (!empty($places)) {
+ return $places;
}
}
diff --git a/app/GedcomRecord.php b/app/GedcomRecord.php
index f7c595b506..2336771d32 100644
--- a/app/GedcomRecord.php
+++ b/app/GedcomRecord.php
@@ -1039,7 +1039,7 @@ class GedcomRecord {
*
* @param string $event_type
*
- * @return array|Place[]
+ * @return Place[]
*/
public function getAllEventPlaces($event_type) {
$places = [];
diff --git a/app/Individual.php b/app/Individual.php
index 6f29bb6e33..35d9e4a9fd 100644
--- a/app/Individual.php
+++ b/app/Individual.php
@@ -540,13 +540,13 @@ class Individual extends GedcomRecord {
/**
* Gat all the birth places - for the individual lists.
*
- * @return array|Place[]
+ * @return Place[]
*/
public function getAllBirthPlaces() {
foreach (explode('|', WT_EVENTS_BIRT) as $event) {
- $tmp = $this->getAllEventPlaces($event);
- if ($tmp) {
- return $tmp;
+ $places = $this->getAllEventPlaces($event);
+ if (!empty($places)) {
+ return $places;
}
}
@@ -572,13 +572,13 @@ class Individual extends GedcomRecord {
/**
* Get all the death places - for the individual lists.
*
- * @return array|Place[]
+ * @return Place[]
*/
public function getAllDeathPlaces() {
foreach (explode('|', WT_EVENTS_DEAT) as $event) {
- $tmp = $this->getAllEventPlaces($event);
- if ($tmp) {
- return $tmp;
+ $places = $this->getAllEventPlaces($event);
+ if (!empty($places)) {
+ return $places;
}
}
diff --git a/app/Place.php b/app/Place.php
index 0e00c384c1..b816294f26 100644
--- a/app/Place.php
+++ b/app/Place.php
@@ -222,7 +222,7 @@ class Place {
*
* @param Tree $tree
*
- * @return array|Place[]
+ * @return Place[]
*/
public static function allPlaces(Tree $tree) {
$places = [];
@@ -258,7 +258,7 @@ class Place {
* @param string $filter
* @param Tree $tree
*
- * @return array|Place[]
+ * @return Place[]
*/
public static function findPlaces($filter, Tree $tree) {
$places = [];