Skip to content

Commit

Permalink
line 39 support for PHP below 5.5
Browse files Browse the repository at this point in the history
  • Loading branch information
mootensai committed Feb 22, 2016
1 parent 36f782f commit cf12c61
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion RelationTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function loadAll($POST)
if ($isManyMany) {
$container = [];
foreach ($value as $relPost) {
if (!empty(array_filter($relPost))) {
if (array_filter($relPost)) {
$condition = [];
$condition[$this->primaryKey()[0]] = $this->primaryKey;
foreach ($relPost as $relAttr => $relAttrVal) {
Expand Down Expand Up @@ -170,6 +170,7 @@ public function saveAll()
}
} else {
//No Children left
//echo "No Children left";
if (!$this->isNewRecord) {
$relData = $this->getRelationData();
foreach ($relData as $rel) {
Expand Down

0 comments on commit cf12c61

Please sign in to comment.