From 95dae58e67f449a161dbd5e86daffe447ef3883d Mon Sep 17 00:00:00 2001 From: Roldan Montilla Jr Date: Wed, 27 Mar 2024 12:50:56 +0800 Subject: [PATCH] revert: remove google analytics in the app (#610) closes #609 --- README.md | 4 ---- app/electron/package.json | 2 -- app/electron/src/helpers/analytics.ts | 15 --------------- app/electron/src/main.ts | 2 -- yarn.lock | 18 ++---------------- 5 files changed, 2 insertions(+), 39 deletions(-) delete mode 100644 app/electron/src/helpers/analytics.ts diff --git a/README.md b/README.md index 55945906..9c80fe3e 100644 --- a/README.md +++ b/README.md @@ -202,10 +202,6 @@ Download the latest version from the [Releases Page](https://github.com/zidoro/p Please consider starring this project to show your :blue_heart: and support. Thank you so much :bowing_man: -## :shield: Privacy - -This app has analytics that will track the number of users only and nothing more ([analytics.ts](https://github.com/zidoro/pomatez/blob/master/app/electron/src/helpers/analytics.ts)). - ## :newspaper: License MIT © [Roldan Montilla Jr](https://github.com/roldanjr) diff --git a/app/electron/package.json b/app/electron/package.json index 79f4ebf5..8f5e86de 100644 --- a/app/electron/package.json +++ b/app/electron/package.json @@ -91,7 +91,6 @@ "electron-updater": "^4.6.5", "lodash.debounce": "^4.0.8", "node-notifier": "10.0.1", - "universal-analytics": "^0.4.23", "uuid": "7.0.3", "v8-compile-cache": "^2.1.1" }, @@ -101,7 +100,6 @@ "electron-devtools-installer": "^3.2.0", "@types/lodash.debounce": "^4.0.6", "@types/node-notifier": "8.0.2", - "@types/universal-analytics": "^0.4.4", "@types/uuid": "7.0.3", "babel-core": "^6.26.3", "babel-jest": "^26.6.3", diff --git a/app/electron/src/helpers/analytics.ts b/app/electron/src/helpers/analytics.ts deleted file mode 100644 index e9e3bb9d..00000000 --- a/app/electron/src/helpers/analytics.ts +++ /dev/null @@ -1,15 +0,0 @@ -import ua from "universal-analytics"; -import { v4 as uuid } from "uuid"; - -import store from "../store"; - -const userId = store.safeGet("userId") || uuid(); - -store.safeSet("userId", userId); - -function activateUser() { - const user = ua("UA-172128342-2", userId); - user.pageview("/").send(); -} - -export { activateUser }; diff --git a/app/electron/src/main.ts b/app/electron/src/main.ts index 2361fbd8..ed9ca0ee 100644 --- a/app/electron/src/main.ts +++ b/app/electron/src/main.ts @@ -34,7 +34,6 @@ import { getFromStorage, createContextMenu, } from "./helpers"; -import { activateUser } from "./helpers/analytics"; import isDev from "electron-is-dev"; import store from "./store"; @@ -361,7 +360,6 @@ if (!onlySingleInstance) { }, }); }); - activateUser(); } ipcMain.on(SET_ALWAYS_ON_TOP, (e, { alwaysOnTop }) => { diff --git a/yarn.lock b/yarn.lock index 8d76d1d8..0bdac57a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4339,11 +4339,6 @@ resolved "https://registry.yarnpkg.com/@types/unist/-/unist-2.0.8.tgz#bb197b9639aa1a04cf464a617fe800cccd92ad5c" integrity sha512-d0XxK3YTObnWVp6rZuev3c49+j4Lo8g4L1ZRm9z5L0xpoZycUPshHgczK5gsUMaZOstjVYYi09p5gYvUtfChYw== -"@types/universal-analytics@^0.4.4": - version "0.4.5" - resolved "https://registry.yarnpkg.com/@types/universal-analytics/-/universal-analytics-0.4.5.tgz#6a4a88477a70f7ca1ce19caede561ca728149810" - integrity sha512-Opb+Un786PS3te24VtJR/QPmX00P/pXaJQtLQYJklQefP4xP0Ic3mPc2z6SDz97OrITzR+RHTBEwjtNRjZ/nLQ== - "@types/uuid@7.0.3": version "7.0.3" resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-7.0.3.tgz#45cd03e98e758f8581c79c535afbd4fc27ba7ac8" @@ -15463,7 +15458,7 @@ request-promise-native@^1.0.7: stealthy-require "^1.1.1" tough-cookie "^2.3.3" -request@^2.88.0, request@^2.88.2: +request@^2.88.0: version "2.88.2" resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== @@ -17575,15 +17570,6 @@ unist-util-visit@^2.0.0: unist-util-is "^4.0.0" unist-util-visit-parents "^3.0.0" -universal-analytics@^0.4.23: - version "0.4.23" - resolved "https://registry.yarnpkg.com/universal-analytics/-/universal-analytics-0.4.23.tgz#d915e676850c25c4156762471bdd7cf2eaaca8ac" - integrity sha512-lgMIH7XBI6OgYn1woDEmxhGdj8yDefMKg7GkWdeATAlQZFrMrNyxSkpDzY57iY0/6fdlzTbBV03OawvvzG+q7A== - dependencies: - debug "^4.1.1" - request "^2.88.2" - uuid "^3.0.0" - universal-user-agent@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/universal-user-agent/-/universal-user-agent-6.0.0.tgz#3381f8503b251c0d9cd21bc1de939ec9df5480ee" @@ -17739,7 +17725,7 @@ uuid@7.0.3: resolved "https://registry.yarnpkg.com/uuid/-/uuid-7.0.3.tgz#c5c9f2c8cf25dc0a372c4df1441c41f5bd0c680b" integrity sha512-DPSke0pXhTZgoF/d+WSt2QaKMCFSfx7QegxEWT+JOuHF5aWrKEn0G+ztjuJg/gG8/ItK+rbPCD/yNv8yyih6Cg== -uuid@^3.0.0, uuid@^3.3.2: +uuid@^3.3.2: version "3.4.0" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==