23 lines
363 B
PHP
23 lines
363 B
PHP
|
<?php
|
||
|
/**
|
||
|
*
|
||
|
*/
|
||
|
|
||
|
namespace Sikofitt\Config;
|
||
|
|
||
|
trait ConfigTrait
|
||
|
{
|
||
|
/**
|
||
|
* @param $name
|
||
|
* @param null $value
|
||
|
* @return mixed
|
||
|
*/
|
||
|
public function config($name, $value = null) {
|
||
|
if(null === $value) {
|
||
|
return $this['config']->get ($name);
|
||
|
} else {
|
||
|
$this['config']->set($name, $value);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|