kartikk221 / hyper-express

High performance Node.js webserver with a simple-to-use API powered by uWebsockets.js under the hood.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

.all('*') not longer working or able to be used not even one time

joacub opened this issue · comments

.all('*') not longer working or able to be used not even one time, server returns an error that the route can not be duplicated and it is not been yet used, maybe you are using this in the core and we are not able to used in our code any more.

im now force to do this insted:

Instead this:

hyperExpressApp.all('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });

i have to use this:

hyperExpressApp.post('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });
  hyperExpressApp.get('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });
  hyperExpressApp.patch('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });
  hyperExpressApp.upgrade('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });
  hyperExpressApp.delete('*', (request, response) => {
    // @ts-expect-error hide this
    return response.json(response.data);
  });

A fix for this bug has been pushed in the recent v6.14.0 update. Please update your hyper-express version and you should be able to use the original code.