more logging
This commit is contained in:
parent
39b89b40ba
commit
89fb5f2d2a
10
src/index.ts
10
src/index.ts
|
@ -85,7 +85,10 @@ const runRestarts = async (status: Awaited<ReturnType<typeof periodicCheck>>) =>
|
||||||
result.stdout?.on('data', data => console.log(data));
|
result.stdout?.on('data', data => console.log(data));
|
||||||
result.stderr?.on('data', data => console.log(data));
|
result.stderr?.on('data', data => console.log(data));
|
||||||
result.on('exit', code => {
|
result.on('exit', code => {
|
||||||
if (code != 0) restarting.bot = false; // Assume restart command has failed
|
if (code != 0) {
|
||||||
|
console.log('Bot: Restart command seems to have failed!');
|
||||||
|
restarting.bot = false;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
console.log(e);
|
console.log(e);
|
||||||
|
@ -100,7 +103,10 @@ const runRestarts = async (status: Awaited<ReturnType<typeof periodicCheck>>) =>
|
||||||
result.stdout?.on('data', data => console.log(data));
|
result.stdout?.on('data', data => console.log(data));
|
||||||
result.stderr?.on('data', data => console.log(data));
|
result.stderr?.on('data', data => console.log(data));
|
||||||
result.on('exit', code => {
|
result.on('exit', code => {
|
||||||
if (code != 0) restarting.bridge = false;
|
if (code != 0) {
|
||||||
|
console.log('Bridge: Restart command seems to have failed!');
|
||||||
|
restarting.bridge = false;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
console.log(e);
|
console.log(e);
|
||||||
|
|
Loading…
Reference in a new issue