core-nails 1.0.9 → 1.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -113,19 +113,19 @@ export async function POST(req: Request) {
|
|
|
113
113
|
const apiIdRouteContent = `import ${camelName}Controller from "@controller/${camelName}";
|
|
114
114
|
|
|
115
115
|
export async function GET(req: Request, { params }: { params: { id: string } }) {
|
|
116
|
-
return ${camelName}Controller.show_action(req, params.id);
|
|
116
|
+
return ${camelName}Controller.show_action(req, (await params).id);
|
|
117
117
|
}
|
|
118
118
|
|
|
119
119
|
export async function PATCH(req: Request, { params }: { params: { id: string } }) {
|
|
120
|
-
return ${camelName}Controller.update_action(req, params.id);
|
|
120
|
+
return ${camelName}Controller.update_action(req, (await params).id);
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
export async function PUT(req: Request, { params }: { params: { id: string } }) {
|
|
124
|
-
return ${camelName}Controller.update_action(req, params.id);
|
|
124
|
+
return ${camelName}Controller.update_action(req, (await params).id);
|
|
125
125
|
}
|
|
126
126
|
|
|
127
127
|
export async function DELETE(req: Request, { params }: { params: { id: string } }) {
|
|
128
|
-
return ${camelName}Controller.destroy_action(req, params.id);
|
|
128
|
+
return ${camelName}Controller.destroy_action(req, (await params).id);
|
|
129
129
|
}
|
|
130
130
|
`;
|
|
131
131
|
|