|
@@ -24,11 +24,13 @@ use Illuminate\Database\Eloquent\Model;
|
|
|
*/
|
|
|
trait BaseControllerConfig
|
|
|
{
|
|
|
+ private $field = [];
|
|
|
public function __get($name)
|
|
|
{
|
|
|
if (!isset($this->field[$name])) {
|
|
|
- return $this->$name();
|
|
|
+ $this->field[$name] = $this->$name();
|
|
|
}
|
|
|
+ return $this->field[$name];
|
|
|
}
|
|
|
|
|
|
protected function channel(): Model
|