mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-07 06:30:53 +03:00
use text/plain on /api/metrics
This commit is contained in:
@@ -2,7 +2,7 @@ const { sendBatch, clientEvent } = require('../amplitude');
|
||||
|
||||
module.exports = async function(req, res) {
|
||||
try {
|
||||
const data = req.body;
|
||||
const data = JSON.parse(req.body); // see http://crbug.com/490015
|
||||
const deltaT = Date.now() - data.now;
|
||||
const events = data.events.map(e =>
|
||||
clientEvent(
|
||||
|
||||
Reference in New Issue
Block a user