mirror of
https://github.com/notion-enhancer/notion-enhancer.git
synced 2025-04-04 12:49:03 +00:00
fix: enable telemetry by default
This commit is contained in:
parent
0fff732fd9
commit
3e379f44e8
@ -13,7 +13,7 @@ function Telemetry() {
|
||||
const { html, initDatabase } = globalThis.__enhancerApi,
|
||||
_get = async () => {
|
||||
// defaults to true, must be explicitly set to false to disable
|
||||
return initDatabase().get("telemetryEnabled") ?? true;
|
||||
return (await initDatabase().get("telemetryEnabled")) ?? true;
|
||||
},
|
||||
_set = async (value) => {
|
||||
await initDatabase().set("telemetryEnabled", value);
|
||||
|
@ -18,7 +18,7 @@ const collectTelemetryData = async () => {
|
||||
sendTelemetryPing = async () => {
|
||||
const db = globalThis.__enhancerApi.initDatabase(),
|
||||
agreedToTerms = await db.get("agreedToTerms"),
|
||||
telemetryEnabled = await db.get("telemetryEnabled");
|
||||
telemetryEnabled = (await db.get("telemetryEnabled")) ?? true;
|
||||
if (!telemetryEnabled || agreedToTerms !== version) return;
|
||||
// telemetry
|
||||
const telemetryData = await collectTelemetryData();
|
||||
|
Loading…
Reference in New Issue
Block a user