App\Http\Controllers\User\Settings\SettingController::updateJoin PHP Метод

updateJoin() публичный Метод

update Join setting
public updateJoin ( CaptchaManager $captcha ) : Illuminate\Http\RedirectResponse
$captcha Xpressengine\Captcha\CaptchaManager
Результат Illuminate\Http\RedirectResponse
    public function updateJoin(CaptchaManager $captcha)
    {
        $inputs = Input::except('_token');
        $config = app('xe.config')->get('user.join');
        if ($inputs['useCaptcha'] === 'true' && !$captcha->available()) {
            throw new ConfigurationNotExistsException();
        }
        foreach ($inputs as $key => $val) {
            $config->set($key, $val);
        }
        app('xe.config')->modify($config);
        return redirect()->back()->with('alert', ['type' => 'success', 'message' => '저장되었습니다.']);
    }