Skip to content

Delete operations are failing with RestApiHandler and NextRequestHandler #1668

@hasan-aa

Description

@hasan-aa

Description and expected behavior
When using RestApiHandler with NextRequestHandler delete operations are failing.
RestApiHandler is returning undefined on the body after successful delete.
Then NextRequestHandler is trying to serialize it as JSON and failing.
"message": "An unhandled error occurred: TypeError: Value is not JSON serializable"

Screenshots
server/api/rest/index.js
Screenshot 2024-08-28 at 20 34 04

app-route-handler.js
Screenshot 2024-08-28 at 20 34 31

Environment (please complete the following information):

  • ZenStack version: 2.4.1
  • Prisma version: 5.18.0
  • Database type: Postgresql

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions