From e0bb19bfaba3d8eff463a7783d0bcccced3b8374 Mon Sep 17 00:00:00 2001 From: Cadence Ember Date: Mon, 2 Sep 2024 00:15:00 +1200 Subject: [PATCH] /bridge: search substrings rather than startswith --- discord/interactions/bridge.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discord/interactions/bridge.js b/discord/interactions/bridge.js index b2d1ac0f..1fbc57e0 100644 --- a/discord/interactions/bridge.js +++ b/discord/interactions/bridge.js @@ -70,7 +70,7 @@ async function interactAutocomplete({id, token, data, guild_id}) { let rooms = await getCachedHierarchy(spaceID) // @ts-ignore - rooms = rooms.filter(r => r.name.startsWith(data.options[0].value)) + rooms = rooms.filter(r => r.name.includes(data.options[0].value)) await discord.snow.interaction.createInteractionResponse(id, token, { type: DiscordTypes.InteractionResponseType.ApplicationCommandAutocompleteResult,