remove unnecessary check

This commit is contained in:
eko 2025-11-27 22:18:13 +07:00
parent a9bbe4dd84
commit 44d23f6e73
1 changed files with 20 additions and 20 deletions

View File

@ -77,30 +77,30 @@ export const createServer = async () => {
}); });
} }
console.log(`[DEBUG] Ensuring server is not running...`); // console.log(`[DEBUG] Ensuring server is not running...`);
await ensureNotRunning(); // await ensureNotRunning();
console.log(`[DEBUG] Starting Bun.serve on port ${g.port}...`); console.log(`[DEBUG] Starting Bun.serve on port ${g.port}...`);
// First try a minimal test server to isolate Bun.serve issues // First try a minimal test server to isolate Bun.serve issues
console.log(`[DEBUG] Creating minimal test server first...`); // console.log(`[DEBUG] Creating minimal test server first...`);
try { // try {
const testServer = Bun.serve({ // const testServer = Bun.serve({
port: 3001, // Use different port for testing // port: 3001, // Use different port for testing
hostname: "0.0.0.0", // hostname: "0.0.0.0",
development: false, // development: false,
fetch(req) { // fetch(req) {
console.log(`[TEST] Minimal server request: ${req.method} ${req.url}`); // console.log(`[TEST] Minimal server request: ${req.method} ${req.url}`);
return new Response("Test server working!", { // return new Response("Test server working!", {
status: 200, // status: 200,
headers: { "Content-Type": "text/plain" } // headers: { "Content-Type": "text/plain" }
}); // });
}, // },
}); // });
console.log(`[DEBUG] ✓ Test server listening on ${testServer.hostname}:${testServer.port}`); // console.log(`[DEBUG] ✓ Test server listening on ${testServer.hostname}:${testServer.port}`);
} catch (testError) { // } catch (testError) {
console.error(`[ERROR] Test server failed:`, testError); // console.error(`[ERROR] Test server failed:`, testError);
} // }
try { try {
g.server = Bun.serve({ g.server = Bun.serve({