Skip to content

Commit 9a0e104

Browse files
committed
fix(route/rumble): prefer videos tab for channel feed
1 parent 30bc707 commit 9a0e104

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/routes/rumble/channel.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export const route: Route = {
3131
},
3232
radar: [
3333
{
34-
source: ['rumble.com/c/:channel'],
34+
source: ['rumble.com/c/:channel', 'rumble.com/c/:channel/videos'],
3535
target: '/c/:channel',
3636
},
3737
],
@@ -205,8 +205,9 @@ async function handler(ctx) {
205205
const channel = ctx.req.param('channel');
206206
const includeEmbed = !ctx.req.param('embed');
207207
const channelUrl = new URL(`/c/${encodeURIComponent(channel)}`, rootUrl).href;
208+
const videosUrl = `${channelUrl}/videos`;
208209

209-
const response = await ofetch(channelUrl, {
210+
const response = await ofetch(videosUrl, {
210211
retryStatusCodes: [403],
211212
});
212213

@@ -230,7 +231,7 @@ async function handler(ctx) {
230231

231232
return {
232233
title: `Rumble - ${title}`,
233-
link: channelUrl,
234+
link: videosUrl,
234235
item: items.filter((item): item is DataItem => Boolean(item && item.link)),
235236
};
236237
}

0 commit comments

Comments
 (0)