Add Prettier and ESLint tooling (Refs #77)
This commit is contained in:
@@ -3,7 +3,10 @@ import { monitoringStatus } from './health-observations.js';
|
||||
import { MonitoringSnapshot } from './monitoring-snapshot.js';
|
||||
|
||||
/** Read only the accepted, current-instance sample; never dispatch a probe. */
|
||||
export function observedPlayerCapacity(server: string, snapshot: MonitoringSnapshot): PlayerCapacityObservation {
|
||||
export function observedPlayerCapacity(
|
||||
server: string,
|
||||
snapshot: MonitoringSnapshot
|
||||
): PlayerCapacityObservation {
|
||||
const game = monitoringStatus(server, snapshot)?.game;
|
||||
const capacity = game?.result.ok ? game.result.status.capacity : null;
|
||||
return typeof capacity === 'number' && Number.isSafeInteger(capacity) && capacity > 0
|
||||
|
||||
Reference in New Issue
Block a user