Default autoscaling empty duration to fifteen minutes
This commit is contained in:
@@ -52,5 +52,5 @@ export function scalingSettings(input: unknown): ScalingSettings {
|
||||
const minimum = integer('minimum', 1, 20), maximum = integer('maximum', undefined, 20), spares = integer('spares', 1, 20);
|
||||
if (minimum > maximum || spares > maximum) throw new Error('Minimum and spare target cannot exceed the maximum.');
|
||||
return { game, mapSlug, mode: mode as AutoscalingMode, minimum, maximum, spares,
|
||||
emptyMinutes: integer('emptyMinutes', 20, 1440) };
|
||||
emptyMinutes: integer('emptyMinutes', 15, 1440) };
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
let snapshot = $state<ScalingReport | null>(null);
|
||||
const report = $derived(snapshot ?? data.autoscaling);
|
||||
const canOperate = $derived(page.data.user?.role === 'admin' || page.data.user?.role === 'operator');
|
||||
const defaults = (): ScalingSettings => ({ game: 't5', mapSlug: 'theater', mode: 'off', minimum: 1, maximum: 3, spares: 1, emptyMinutes: 20 });
|
||||
const defaults = (): ScalingSettings => ({ game: 't5', mapSlug: 'theater', mode: 'off', minimum: 1, maximum: 3, spares: 1, emptyMinutes: 15 });
|
||||
let settings = $state<ScalingSettings>(defaults());
|
||||
let editing = $state<ScalingPolicy | null>(null);
|
||||
let editorOpen = $state(false);
|
||||
|
||||
Reference in New Issue
Block a user