优化结构

This commit is contained in:
2026-06-18 21:44:37 +08:00 Unverified
parent 3051fe2d6a
commit cb244eb983
74 changed files with 94 additions and 144 deletions
+2 -2
View File
@@ -1,7 +1,7 @@
import { getAllPosts } from '@/lib/posts';
export function GET() {
const posts = getAllPosts().map((post) => ({
export async function GET() {
const posts = (await getAllPosts()).map((post) => ({
title: post.title,
href: post.href,
}));