mirror of
https://github.com/agam778/MS-365-Electron.git
synced 2026-02-17 09:02:10 +00:00
Remove Aptabase Tracking
This commit is contained in:
@@ -326,35 +326,6 @@ const commonPreferencesSubmenu = [
|
||||
},
|
||||
checked: getValue("discordrpcstatus") === "true",
|
||||
},
|
||||
{
|
||||
label: "Enable Aptabase Tracking",
|
||||
type: "checkbox",
|
||||
click: () => {
|
||||
if (getValue("aptabaseTracking") === true) {
|
||||
setValue("aptabaseTracking", false);
|
||||
dialog.showMessageBoxSync({
|
||||
type: "info",
|
||||
title: "Aptabase Tracking",
|
||||
message: "Aptabase Tracking has been disabled.",
|
||||
buttons: ["OK"],
|
||||
});
|
||||
return;
|
||||
} else if (
|
||||
getValue("aptabaseTracking") === false ||
|
||||
getValue("aptabaseTracking") === undefined
|
||||
) {
|
||||
setValue("aptabaseTracking", true);
|
||||
dialog.showMessageBoxSync({
|
||||
type: "info",
|
||||
title: "Aptabase Tracking",
|
||||
message: "Aptabase Tracking has been enabled.",
|
||||
buttons: ["OK"],
|
||||
});
|
||||
return;
|
||||
}
|
||||
},
|
||||
checked: getValue("aptabaseTracking") === true,
|
||||
},
|
||||
{
|
||||
label: "Enable Auto Updates",
|
||||
type: "checkbox",
|
||||
|
||||
@@ -32,7 +32,6 @@ getValueOrDefault("custompage", "home");
|
||||
getValueOrDefault("windowWidth", 0.71);
|
||||
getValueOrDefault("windowHeight", 0.74);
|
||||
getValueOrDefault("customWindowSize", false);
|
||||
getValueOrDefault("aptabaseTracking", null);
|
||||
getValueOrDefault("externalLinks", "true");
|
||||
|
||||
if (getValue("enterprise-or-normal") === "https://microsoft365.com/?auth=1") {
|
||||
|
||||
27
app/main.js
27
app/main.js
@@ -1,6 +1,5 @@
|
||||
import { app, Menu, BrowserWindow, dialog, nativeImage, shell } from "electron";
|
||||
import { clearActivity, setActivity, loginToRPC } from "./config/rpc.js";
|
||||
import { initialize, trackEvent } from "@aptabase/electron/main";
|
||||
import { ElectronBlocker } from "@cliqz/adblocker-electron";
|
||||
import { setValue, getValue } from "./config/store.js";
|
||||
import { dirname, join } from "path";
|
||||
@@ -27,12 +26,6 @@ transports.file.level = "verbose";
|
||||
console.log = _log;
|
||||
Object.assign(console, functions);
|
||||
|
||||
if (getValue("aptabaseTracking") === true) {
|
||||
initialize("A-US-2528580917").catch((error) => {
|
||||
console.error("Error initializing:", error);
|
||||
});
|
||||
}
|
||||
|
||||
function createWindow() {
|
||||
const enterpriseOrNormal = getValue("enterprise-or-normal");
|
||||
const custompage = getValue("custompage");
|
||||
@@ -69,11 +62,6 @@ function createWindow() {
|
||||
win.webContents.on("did-finish-load", () => {
|
||||
splash.destroy();
|
||||
win.show();
|
||||
if (getValue("aptabaseTracking") === true) {
|
||||
trackEvent("app_started").catch((error) => {
|
||||
console.error("Error tracking event:", error);
|
||||
});
|
||||
}
|
||||
if (getValue("discordrpcstatus") === "true") {
|
||||
setActivity(`On "${win.webContents.getTitle()}"`);
|
||||
}
|
||||
@@ -122,21 +110,6 @@ Menu.setApplicationMenu(Menu.buildFromTemplate(menulayout));
|
||||
|
||||
app.on("ready", () => {
|
||||
createWindow();
|
||||
if (getValue("aptabaseTracking") === null) {
|
||||
const aptabasedialog = dialog.showMessageBoxSync({
|
||||
type: "question",
|
||||
buttons: ["Yes", "No"],
|
||||
title: "Enable Aptabase Tracking",
|
||||
message: "Would you like to enable Aptabase Tracking?",
|
||||
detail:
|
||||
"Aptabase Tracking helps us improve the app by collecting anonymous usage data. No personal information is collected.\n\nYou can always enable or disable this in the app menu.",
|
||||
});
|
||||
if (aptabasedialog === 0) {
|
||||
setValue("aptabaseTracking", true);
|
||||
} else {
|
||||
setValue("aptabaseTracking", false);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
app.on("web-contents-created", (event, contents) => {
|
||||
|
||||
@@ -74,7 +74,6 @@
|
||||
"prettier-eslint": "^16.1.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@aptabase/electron": "^0.3.1",
|
||||
"@cliqz/adblocker-electron": "^1.26.6",
|
||||
"@xhayper/discord-rpc": "^1.0.21",
|
||||
"axios": "^1.4.0",
|
||||
|
||||
10
yarn.lock
10
yarn.lock
@@ -12,15 +12,6 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@aptabase/electron@npm:^0.3.1":
|
||||
version: 0.3.1
|
||||
resolution: "@aptabase/electron@npm:0.3.1"
|
||||
peerDependencies:
|
||||
electron: ">= 3.x"
|
||||
checksum: 10c0/f26e48f2e3449faf19c36d2ad2a3eb13269ad851187c93f1f095d39d11153108628faa3c70cd3e24ad760f5f0bf8b24d1b7675b2dcc652f500bf46b2c31db2e1
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@cliqz/adblocker-content@npm:^1.34.0":
|
||||
version: 1.34.0
|
||||
resolution: "@cliqz/adblocker-content@npm:1.34.0"
|
||||
@@ -3806,7 +3797,6 @@ __metadata:
|
||||
version: 0.0.0-use.local
|
||||
resolution: "ms-365-electron@workspace:."
|
||||
dependencies:
|
||||
"@aptabase/electron": "npm:^0.3.1"
|
||||
"@cliqz/adblocker-electron": "npm:^1.26.6"
|
||||
"@xhayper/discord-rpc": "npm:^1.0.21"
|
||||
axios: "npm:^1.4.0"
|
||||
|
||||
Reference in New Issue
Block a user