image works in DM
This commit is contained in:
@@ -3,6 +3,7 @@ import type { Command } from "commander";
|
||||
import { loadConfig } from "../config/config.js";
|
||||
import { sendMessageDiscord } from "../discord/send.js";
|
||||
import { sendMessageIMessage } from "../imessage/send.js";
|
||||
import { sendMessageMSTeams } from "../msteams/send.js";
|
||||
import { PROVIDER_ID_LABELS } from "../pairing/pairing-labels.js";
|
||||
import {
|
||||
approveProviderPairingCode,
|
||||
@@ -21,6 +22,7 @@ const PROVIDERS: PairingProvider[] = [
|
||||
"discord",
|
||||
"slack",
|
||||
"whatsapp",
|
||||
"msteams",
|
||||
];
|
||||
|
||||
function parseProvider(raw: unknown): PairingProvider {
|
||||
@@ -65,6 +67,11 @@ async function notifyApproved(provider: PairingProvider, id: string) {
|
||||
await sendMessageIMessage(id, message);
|
||||
return;
|
||||
}
|
||||
if (provider === "msteams") {
|
||||
const cfg = loadConfig();
|
||||
await sendMessageMSTeams({ cfg, to: id, text: message });
|
||||
return;
|
||||
}
|
||||
// WhatsApp: approval still works (store); notifying requires an active web session.
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user