Fixed XML error in Firefox. Renamed telemetry env var.

This commit is contained in:
Mike Cao 2022-03-18 19:02:23 -07:00
parent 934914d249
commit 281671b792
2 changed files with 2 additions and 2 deletions

View File

@ -2,7 +2,7 @@ require('dotenv').config();
const sendTelemetry = require('./telemetry');
async function run() {
if (!process.env.TELEMETRY_DISABLE) {
if (!process.env.DISABLE_TELEMETRY) {
await sendTelemetry();
}
}

View File

@ -48,7 +48,7 @@ import { removeTrailingSlash } from '../lib/url';
const post = (url, data, callback) => {
const req = new XMLHttpRequest();
req.open('POST', url, true);
req.setRequestHeader('Content-Type', 'text/plain');
req.setRequestHeader('Content-Type', 'application/json');
req.onreadystatechange = () => {
if (req.readyState === 4) {