Remove check for unimplemented twitfix api endpoints

This commit is contained in:
dangered wolf 2023-11-03 16:42:24 -04:00
parent e7d9e2f460
commit efa8cb42a0
No known key found for this signature in database
GPG key ID: 41E4D37680ED8B58
2 changed files with 0 additions and 19 deletions

View file

@ -186,9 +186,6 @@ This is caused by Twitter API downtime or a new bug. Try again in a little while
ERROR_USER_NOT_FOUND: `Sorry, that user doesn't exist :(`, ERROR_USER_NOT_FOUND: `Sorry, that user doesn't exist :(`,
ERROR_UNKNOWN: `Unknown error occurred, sorry about that :(`, ERROR_UNKNOWN: `Unknown error occurred, sorry about that :(`,
TWITFIX_API_SUNSET: `The original TwitFix API has been sunset. To learn more about the FixTweet API, check out <a href="https://${
API_HOST_LIST.split(',')[0]
}">${API_HOST_LIST.split(',')[0]}</a>`,
DEPRECATED_DOMAIN_NOTICE: `We've moved! ➡ fxtwitter.com`, DEPRECATED_DOMAIN_NOTICE: `We've moved! ➡ fxtwitter.com`,
DEPRECATED_DOMAIN_NOTICE_DISCORD: `We've moved! ➡ fxtwitter.com`, DEPRECATED_DOMAIN_NOTICE_DISCORD: `We've moved! ➡ fxtwitter.com`,

View file

@ -547,22 +547,6 @@ export const cacheWrapper = async (request: Request, event?: FetchEvent): Promis
}); });
} }
/* Some TwitFix APIs will never be available in FixTweet for privacy or
design choice reasons.
Trying to access these APIs result in a message saying TwitFix API
has been sunset. */
if (
cacheUrl.pathname.startsWith('/api/') ||
cacheUrl.pathname.startsWith('/other/') ||
cacheUrl.pathname.startsWith('/info/')
) {
return new Response(Strings.TWITFIX_API_SUNSET, {
headers: Constants.RESPONSE_HEADERS,
status: 410
});
}
switch (request.method) { switch (request.method) {
case 'GET': case 'GET':
if ( if (