diff options
| author | Markus Uhlin <markus@nifty-networks.net> | 2025-11-21 19:16:46 +0100 |
|---|---|---|
| committer | Markus Uhlin <markus@nifty-networks.net> | 2025-11-21 19:16:46 +0100 |
| commit | ecd937337de61f2123a3272e5eb6e25b96e38bbd (patch) | |
| tree | 99cc5a4aa8e10838b00242680374c242f4ebd286 | |
| parent | 6d526bff1ad6087da6ff08a746aaa6cb55ce3545 (diff) | |
Save levels of indentation
| -rw-r--r-- | FICS/settings.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/FICS/settings.cpp b/FICS/settings.cpp index 388a3cc..20c1dc2 100644 --- a/FICS/settings.cpp +++ b/FICS/settings.cpp @@ -133,12 +133,10 @@ install_setting(const char *name, const char *value) return EINVAL; for (auto it = settings.begin(); it != settings.end(); ++it) { if (strings_match((*it).name.c_str(), name)) { - if (!is_setting_ok(value, (*it).type)) { + if (!is_setting_ok(value, (*it).type)) return EINVAL; - } else { - (*it).value.assign(value); - return 0; - } + (*it).value.assign(value); + return 0; } } return ENOENT; |
