import { getBrowserPool as getHeadlessPoolForWeather } from './services/headless-pool.js'
import { weatherRouter } from './routers/weather-router.js'
import { geoRouter } from './routers/geo-router.js'

process.on('bootstrap-module-global-public-route' as any, (app, globalPublicRouter) => {
  getHeadlessPoolForWeather()

  globalPublicRouter.use('/weather', weatherRouter.routes(), weatherRouter.allowedMethods())
  globalPublicRouter.use('/geo', geoRouter.routes(), geoRouter.allowedMethods())
})
