From e775d4c5e705146aa7de923e78be366e84bc78d4 Mon Sep 17 00:00:00 2001 From: Aholicknight <7843719+Aholicknight@users.noreply.github.com> Date: Fri, 27 Dec 2024 14:26:03 -0600 Subject: [PATCH] Remove resolveShortLink function apply suggestions --- api/src/processing/services/reddit.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/api/src/processing/services/reddit.js b/api/src/processing/services/reddit.js index 61402777..b5283d65 100644 --- a/api/src/processing/services/reddit.js +++ b/api/src/processing/services/reddit.js @@ -48,15 +48,12 @@ async function getAccessToken() { return access_token; } -async function resolveShortLink(url) { - return await getRedirectingURL(url); -} export default async function(obj) { let url; if (obj.shortLink) { - const resolvedUrl = await resolveShortLink(obj.shortLink); + const resolvedUrl = await getRedirectingURL(obj.shortLink); if (!resolvedUrl) return { error: "fetch.short_link" }; url = new URL(resolvedUrl); } else {