From f885492a2284d2ade840a64691785f99d463307c Mon Sep 17 00:00:00 2001 From: freearhey <7253922+freearhey@users.noreply.github.com> Date: Wed, 11 Mar 2026 04:32:38 +0300 Subject: [PATCH] Update edit.ts --- scripts/commands/channels/edit.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/scripts/commands/channels/edit.ts b/scripts/commands/channels/edit.ts index 9e172a65..5d3b2645 100644 --- a/scripts/commands/channels/edit.ts +++ b/scripts/commands/channels/edit.ts @@ -85,8 +85,7 @@ export default async function main(filepath: string) { } async function selectChannel(channel: epgGrabber.Channel): Promise { - const query = escapeRegex(channel.name) - const similarChannels = searchChannels(query) + const similarChannels = searchChannels(channel.name) const choices = getChoicesForChannel(similarChannels).all() const selected: ChoiceValue = await select({ @@ -194,7 +193,3 @@ function save(filepath: string, channelsFromXML: Collection) { console.log() logger.info(`File '${filepath}' successfully saved`) } - -function escapeRegex(string: string) { - return string.replace(/[/\-\\^$*+?.()|[\]{}]/g, '\\$&') -}