Skip to content

Commit

Permalink
fix(route): Jones Lang LaSalle (#17797)
Browse files Browse the repository at this point in the history
  • Loading branch information
nczitzk authored Dec 4, 2024
1 parent 39b5eac commit 147964c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/routes/joneslanglasalle/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const cleanHtml = (html: string, preservedTags: string[]): string => {

export const handler = async (ctx: Context): Promise<Data> => {
const { language: lang = 'zh', category = 'trends-and-insights' } = ctx.req.param();
const limit: number = Number.parseInt(ctx.req.query('limit') ?? '3', 10);
const limit: number = Number.parseInt(ctx.req.query('limit') ?? '10', 10);

const rootUrl: string = 'https://www.joneslanglasalle.com.cn';
const targetUrl: string = new URL(`${lang}/${category}`, rootUrl).href;
Expand Down Expand Up @@ -92,7 +92,7 @@ export const handler = async (ctx: Context): Promise<Data> => {
const guid: string = $$('meta[property="og:url"]').prop('content');
const image: string | undefined = $$('meta[property="og:image"]').prop('content');

const pubDate: Date = parseDate($$('div.publicationdate').text().trim(), ['YYYY 年MM 月DD 日', 'MMMMDD,YYYY']);
const pubDate: Date = parseDate($$('div.publicationdate').text().trim(), ['YYYY 年MM 月DD 日', 'MMMM DD, YYYY']);

const author: DataItem['author'] = $$('div.contributors ul li')
.toArray()
Expand Down Expand Up @@ -199,7 +199,7 @@ export const route: Route = {
category: 'Category, `trends-and-insights` by default',
},
description: `:::tip
If you subscribe to [Trends & Insights](https://www.joneslanglasalle.com.cn/en/trends-and-insights),where the URL is \`https://www.joneslanglasalle.com.cn/en/trends-and-insights\`, extract the part \`https://joneslanglasalle.com.cn/\` to the end. Use \`zh\` and \`trends-and-insights\` as the parameters to fill in. Therefore, the route will be [\`/joneslanglasalle/trends-and-insights/en/trends-and-insights\`](https://rsshub.app/joneslanglasalle/trends-and-insights/en/trends-and-insights).
If you subscribe to [Trends & Insights](https://www.joneslanglasalle.com.cn/en/trends-and-insights),where the URL is \`https://www.joneslanglasalle.com.cn/en/trends-and-insights\`, extract the part \`https://joneslanglasalle.com.cn/\` to the end. Use \`zh\` and \`trends-and-insights\` as the parameters to fill in. Therefore, the route will be [\`/joneslanglasalle/en/trends-and-insights\`](https://rsshub.app/joneslanglasalle/en/trends-and-insights).
:::
| Category | ID |
Expand Down

0 comments on commit 147964c

Please sign in to comment.