fix sighup

This commit is contained in:
Miko 2025-01-24 11:08:47 +01:00 committed by GitHub
parent 9bb270b6c5
commit 5d050709ef
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -775,8 +775,8 @@ export async function server(opts) {
console.log(`Caught signal ${signal}, refreshing`);
console.log('Stopping server and reloading config');
running.server.shutdown(() => {
const restarted = start(opts);
running.server.shutdown(async () => {
const restarted = await start(opts);
running.server = restarted.server;
running.app = restarted.app;
});