mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-10-26 14:42:49 +00:00
feat(dashboard): restarts from 30 seconds; no "undefined" in the restart banner
Restarts can be scheduled in seconds (30 s to 24 h; minutes still accepted), with 30 second and 1 minute choices for quick restarts. The restart banner only names who scheduled it when that is known: staff who manage restarts read it from /api/server/restart, everyone else gets when and why from the status, which leaves the name out. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -33,7 +33,7 @@ namespace LiveWorld {
|
||||
* Schedule a restart in `minutes` (1 to 1440) with in-game warnings, audited as `actor`. One already scheduled is
|
||||
* replaced when `replace`, or kept with an error. The error, if it wasn't scheduled
|
||||
*/
|
||||
std::optional<std::string> ScheduleRestart(int64_t minutes, const std::string& reason, const HTTPContext& actor, bool replace);
|
||||
std::optional<std::string> ScheduleRestart(int64_t seconds, const std::string& reason, const HTTPContext& actor, bool replace);
|
||||
|
||||
// Scheduled restart for the status sent to every dashboard ({} when none)
|
||||
// The scheduled restart ({} when none); the staff member's name only with withStaffName
|
||||
|
||||
Reference in New Issue
Block a user