fix: Fix usage error in /time command

When targeting a specific preference (`/time console off`)
the loop would continue to iterate through the remaining
categories after finding and applying the setting.

Because subsequent items would not match, it always resulted in
"invalid usage" printed as well after the success message.
This commit is contained in:
Michael Vetter
2026-03-04 22:23:31 +01:00
parent 99e7057a36
commit 11bc6ea22b

View File

@@ -5290,6 +5290,9 @@ cmd_time(ProfWin* window, const char* const command, gchar** args)
cons_bad_cmd_usage(command);
return TRUE;
}
if (!set_all) {
break;
}
}
if (!set_all && n == ARRAY_SIZE(time_prefs)) {
cons_bad_cmd_usage(command);