mirror of
https://github.com/KivotosRailway/website.git
synced 2026-11-03 11:06:32 +09:00
修复首页新闻板块未跟随语言的错误
This commit is contained in:
@@ -216,7 +216,7 @@ export async function getNewsBySlug(slug: string, locale: Locale = "zh-CN"): Pro
|
||||
return items.find((item) => item.slug === slug) ?? null;
|
||||
}
|
||||
|
||||
export async function getLatestNews() {
|
||||
const items = await getNewsList();
|
||||
export async function getLatestNews(locale: Locale = "zh-CN") {
|
||||
const items = await getNewsList(locale);
|
||||
return items.slice(0, 3);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user