diff --git a/lib/routes/dsndsht23/index.js b/lib/routes/dsndsht23/index.js index e3ff5c4314..d7c656f44c 100644 --- a/lib/routes/dsndsht23/index.js +++ b/lib/routes/dsndsht23/index.js @@ -21,18 +21,13 @@ const forumIdMaps = { module.exports = async (ctx) => { const subformName = ctx.params.subforumid || 'gqzwzm'; const subformId = subformName in forumIdMaps ? forumIdMaps[subformName] : subformName; - const typefilter = ctx.params.type ? `&filter=type&typeid=${ctx.params.type}` : ''; + const typefilter = ctx.params.type ? `&filter=typeid&typeid=${ctx.params.type}` : ''; const link = `${host}forum.php?mod=forumdisplay&fid=${subformId}${typefilter}`; const response = await got.get(link); const $ = cheerio.load(response.data); - const list = $('#threadlisttableid tbody') - .slice(1, 21) - .filter(function() { - // 去除置顶帖子和分割线 - const threadID = $(this).attr('id'); - return typeof threadID !== 'undefined' && threadID !== 'separatorline' && !threadID.startsWith('stickthread'); - }) + const list = $('#threadlisttableid tbody[id^=normalthread]') + .slice(0, 11) .map(function() { const info = { title: