feat: use capture

This commit is contained in:
karishmas6
2024-10-29 04:00:33 +05:30
parent 159cf3bc63
commit 2b9882774f

View File

@@ -15,7 +15,7 @@ import { SERVER_PORT } from "./constants/config";
import { Server } from "socket.io";
import { readdirSync } from "fs"
import { fork } from 'child_process';
import captureServerAnalytics from "./utils/analytics";
import { capture } from "./utils/analytics";
import swaggerUi from 'swagger-ui-express';
import swaggerSpec from './swagger/config';
@@ -77,10 +77,11 @@ workerProcess.on('exit', (code) => {
});
app.get('/', function (req, res) {
captureServerAnalytics.capture({
distinctId: 'maxun-oss-server-run',
event: 'server_started',
});
capture(
'maxun-oss-server-run', {
event: 'server_started',
}
);
return res.send('Maxun server started 🚀');
});