fix: naming

This commit is contained in:
Arman committed 2022-11-16 16:29:51 +01:00
1 parent cd2b882957
commit a8e92f87d2
1 file changed
+4 -3
+4 -3
View File
@@ -34,9 +34,10 @@ export function trackPageView(path: string) {
function sendEventToGrowth(event: string, path: string, data: object = null): void {
let email: string, name: string;
if (get(user)) {
email = get(user).email;
name = get(user).name;
const userStore = get(user);
if (userStore) {
email = userStore.email;
name = userStore.name;
}
fetch('https://growth.appwrite.io/v1/analytics', {
method: 'POST',