diff options
| -rw-r--r-- | server.mjs | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -4,15 +4,15 @@ const server = createServer((req, res) => { res.writeHead(200, { 'Content-Type': 'text/plain' }) if (req.method === 'GET' && req.url === '/gettime') { - res.end(JSON.stringify({ - time: Math.floor(Date.now() / 1000) - })) + res.end(JSON.stringify({ + time: Math.floor(Date.now() / 1000) + })) } else if (req.method === 'GET' && req.url.startsWith('/eagle')) { - res.end(JSON.stringify({ - status: 200, data: { eagleId: 0 } - })) + res.end(JSON.stringify({ + status: 200, data: { eagleId: 0 } + })) } else { - res.end('It works!\n') + res.end('It works!\n') } }) |
