From b7a8c31988cc478d64cc18e12de94220be82e6c2 Mon Sep 17 00:00:00 2001 From: jtricerolph Date: Wed, 29 Jul 2026 07:50:29 +0000 Subject: [PATCH] =?UTF-8?q?Revert=20mqtt=5Fplant=20=E2=80=94=20go=20back?= =?UTF-8?q?=20to=20one=20shared=20MQTT=20integration?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Per-app MQTT slugs meant a confusing mix of shared and per-app credentials in one settings page. Consolidating on a single shared identity instead — matches the original "MQTT is shared infra" decision, and publish access stays scoped per-device regardless. Co-Authored-By: Claude Sonnet 5 --- src/integrations/schema.js | 5 ----- src/routes/integrations.js | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/integrations/schema.js b/src/integrations/schema.js index 9e0db41..f43c74a 100644 --- a/src/integrations/schema.js +++ b/src/integrations/schema.js @@ -52,11 +52,6 @@ export const INTEGRATIONS = { configFields: ['host', 'port'], secretFields: ['username', 'password'], }, - mqtt_plant: { - name: 'MQTT Broker (Plant)', - configFields: ['host', 'port'], - secretFields: ['username', 'password'], - }, } export const MASKED = '••••••••' diff --git a/src/routes/integrations.js b/src/routes/integrations.js index 3ece339..a8a2125 100644 --- a/src/routes/integrations.js +++ b/src/routes/integrations.js @@ -141,7 +141,7 @@ export async function integrationRoutes(app) { if (res.status === 401) throw new Error('Invalid Nextcloud credentials') if (!res.ok) throw new Error(`Nextcloud returned ${res.status}`) } - else if (req.params.slug === 'mqtt' || req.params.slug.startsWith('mqtt_')) { + else if (req.params.slug === 'mqtt') { if (!creds.host || !creds.username || !creds.password) throw new Error('MQTT host, username and password are required') const mqtt = await import('mqtt') await new Promise((resolve, reject) => {