Send terminate error messages

This commit is contained in:
Owen
2026-01-16 14:57:54 -08:00
parent a126494c12
commit 9114dd5992
11 changed files with 41 additions and 8 deletions

View File

@@ -11,6 +11,7 @@ import logger from "@server/logger";
import { OpenAPITags, registry } from "@server/openApi";
import { rebuildClientAssociationsFromClient } from "@server/lib/rebuildClientAssociations";
import { sendTerminateClient } from "../client/terminate";
import { OlmErrorCodes } from "./error";
const paramsSchema = z
.object({
@@ -76,6 +77,8 @@ export async function deleteUserOlm(
if (olm) {
await sendTerminateClient(
deletedClient.clientId,
OlmErrorCodes.TERMINATED_DELETED,
"Deleted",
olm.olmId
); // the olmId needs to be provided because it cant look it up after deletion
}