type == 'image') { return asset($this->value); } return ''; }); } public static function getByKey($key) { return Setting::where('key', $key)->value('value'); } }