miscfunctions: move configStringToInt to std::expected

This commit is contained in:
Vaxry
2024-11-18 23:53:38 +00:00
parent 936dfedbad
commit 47a1650c48
8 changed files with 106 additions and 72 deletions

View File

@@ -400,7 +400,7 @@ void CLayerSurface::applyRules() {
} else if (rule.rule.starts_with("xray")) {
CVarList vars{rule.rule, 0, ' '};
try {
xray = configStringToInt(vars[1]);
xray = configStringToInt(vars[1]).value_or(false);
} catch (...) {}
} else if (rule.rule.starts_with("animation")) {
CVarList vars{rule.rule, 2, 's'};