import { c as defineEventHandler, g as getQuery } from '../../../_/nitro.mjs';
import findProcess from 'find-process';
import 'node:http';
import 'node:https';
import 'node:events';
import 'node:buffer';
import 'node:fs';
import 'node:path';
import 'node:crypto';
import 'node:url';

const getPort_get = defineEventHandler(async (event) => {
  const port = getQuery(event).port;
  if (port) {
    return findProcess("port", port);
  } else {
    return findProcess("name", "", true);
  }
});

export { getPort_get as default };
//# sourceMappingURL=get-port.get.mjs.map
