Forgot to start Draupnir listening in appservice.

We need to look at Draupnir's .start method and make it `void`.
The report poller should just throw if it fails without being
caught by `Task`.

We also need to test the `toggle` in appservice in integration
tests.
This commit is contained in:
gnuxie
2024-09-19 12:27:39 +01:00
parent 334aaa7233
commit b52948b353
@@ -8,7 +8,12 @@
// https://github.com/matrix-org/mjolnir
// </text>
import { ActionError, ActionResult, isError } from "matrix-protection-suite";
import {
ActionError,
ActionResult,
Task,
isError,
} from "matrix-protection-suite";
import { IConfig } from "../config";
import { DraupnirFactory } from "./DraupnirFactory";
import { Draupnir } from "../Draupnir";
@@ -83,6 +88,7 @@ export class StandardDraupnirManager {
}
this.draupnir.set(clientUserID, draupnir.ok);
this.failedDraupnir.delete(clientUserID);
void Task(draupnir.ok.start());
return draupnir;
}