A free and open source instant messaging and VoIP chat app built for friends, groups, and communities.
fix(app): accept tenor links with a regional locale prefix (#1966)
Hampusde97bf908def
diff --git a/fluxer_app/src/features/expressions/utils/TenorUtils.ts b/fluxer_app/src/features/expressions/utils/TenorUtils.tsindex 3fd8f88b4..05b2bb5a6 100644--- a/fluxer_app/src/features/expressions/utils/TenorUtils.ts+++ b/fluxer_app/src/features/expressions/utils/TenorUtils.ts@@ -20,7 +20,7 @@ export function extractTenorSlugId(url: string): string | null {if (hostname !== 'tenor.com' && hostname !== 'www.tenor.com') {return null;}- const match = parsedUrl.pathname.match(/^\/(?:[a-z]{2}\/)?view\/([^/]+)/i);+ const match = parsedUrl.pathname.match(/^\/(?:[a-z]{2}(?:-[a-z]{2})?\/)?view\/([^/]+)/i);if (!match?.[1]) {return null;}