Skip to content

chore: Migrate server from Hono to XebecServer and update route handlers#3

Merged
itsfuad merged 1 commit intomainfrom
Remove-HONO
Feb 25, 2025
Merged

chore: Migrate server from Hono to XebecServer and update route handlers#3
itsfuad merged 1 commit intomainfrom
Remove-HONO

Conversation

@itsfuad
Copy link
Copy Markdown
Member

@itsfuad itsfuad commented Feb 25, 2025

This pull request includes significant updates to the server/libs/apiServer.ts and server/libs/fileHandler.ts files, primarily focusing on replacing the Hono server with the XebecServer and refactoring the code to use the new server's API.

Server Replacement and Refactoring:

  • Replaced Hono server with XebecServer and updated the server instance creation accordingly in server/libs/apiServer.ts and server/libs/fileHandler.ts. [1] [2]
  • Updated the middleware and route handlers to use the new XebecServer API, including changes in how headers are set and responses are created. [1] [2]

Response Handling:

  • Refactored response handling to use the Response object instead of the ctx object, ensuring consistency with the new server's API. [1] [2] [3] [4]
  • Updated file upload and download endpoints to handle responses and errors using the Response object. [1] [2]

Error Handling:

  • Improved error handling during file uploads and downloads, ensuring proper status codes and messages are returned. [1] [2] [3]

These changes ensure that the server code is compatible with the XebecServer and improve the overall structure and error handling of the application.

@itsfuad itsfuad merged commit 5f86f5f into main Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant