From df943c09d91e536e17d426fbe35b0a8fcdabe26f Mon Sep 17 00:00:00 2001 From: Zed Date: Mon, 9 Mar 2020 00:47:00 +0100 Subject: [PATCH] Fix converted youtube channel links --- src/formatters.nim | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/formatters.nim b/src/formatters.nim index ec7c709..66d165a 100644 --- a/src/formatters.nim +++ b/src/formatters.nim @@ -39,6 +39,8 @@ proc replaceUrl*(url: string; prefs: Prefs; absolute=""): string = result = url if prefs.replaceYouTube.len > 0: result = result.replace(ytRegex, prefs.replaceYouTube) + if prefs.replaceYouTube in result: + result = result.replace("/c/", "/") if prefs.replaceTwitter.len > 0: result = result.replace(tco, "https://" & prefs.replaceTwitter & "/t.co") result = result.replace(cards, prefs.replaceTwitter & "/cards")