organize your functions into middlewares ala express