diff --git a/database.rules.json b/database.rules.json index 2fbd260d8..d136bd684 100644 --- a/database.rules.json +++ b/database.rules.json @@ -7,11 +7,6 @@ ".indexOn": ".value" } }, - "agents": { - "$provider": { - ".indexOn": ".value" - } - }, "assignments": { "$provider": { ".indexOn": ".value" diff --git a/functions/src/subscriptions.ts b/functions/src/subscriptions.ts index 1ac70433b..a5f6e1f0a 100644 --- a/functions/src/subscriptions.ts +++ b/functions/src/subscriptions.ts @@ -35,13 +35,6 @@ export const subscribe = functions.https.onCall(async (data, context) => { // acquire an agent. this might cause a reconnection but it's ok because // the user just opened the app. - await admin - .database() - .ref("agents") - .child(provider) - .child(channel) - .set(""); - await admin .database() .ref("requests") @@ -79,13 +72,6 @@ export const unsubscribe = functions.pubsub console.log("unsubscribing from", provider, channel); // release the agent. - await admin - .database() - .ref("agents") - .child(provider) - .child(channel) - .set(null); - await admin .database() .ref("assignments")