eee
This commit is contained in:
+3
-9
@@ -57,9 +57,7 @@ class Relation extends Component
|
||||
if (Context::exists($_identification)) {
|
||||
return Context::get($_identification);
|
||||
}
|
||||
$activeModel = $this->_query[$_identification]->first();
|
||||
unset($this->_query[$_identification]);
|
||||
return Context::set($_identification, $activeModel);
|
||||
return Context::set($_identification, $this->_query[$_identification]->first());
|
||||
}
|
||||
|
||||
|
||||
@@ -72,9 +70,7 @@ class Relation extends Component
|
||||
if (Context::exists($_identification)) {
|
||||
return Context::get($_identification);
|
||||
}
|
||||
$activeModel = $this->_query[$_identification]->count();
|
||||
unset($this->_query[$_identification]);
|
||||
return Context::set($_identification, $activeModel);
|
||||
return Context::set($_identification, $this->_query[$_identification]->count());
|
||||
}
|
||||
|
||||
|
||||
@@ -88,9 +84,7 @@ class Relation extends Component
|
||||
if (Context::exists($_identification)) {
|
||||
return Context::get($_identification);
|
||||
}
|
||||
$activeModel = $this->_query[$_identification]->get();
|
||||
unset($this->_query[$_identification]);
|
||||
return Context::set($_identification, $activeModel);
|
||||
return Context::set($_identification, $this->_query[$_identification]->get());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user