First, I wasn't looking at the right page
Second, The solution I found to my error:
type Params = Promise<{ id: string }>;
export default async function EditPost({ params }: { params: Params }) {
const { id } = await params;
// rest of the code ...
}