Get electron store working.

This commit is contained in:
Patrick Fic
2025-03-12 14:59:45 -07:00
parent 776d152d88
commit fb991670fe
2 changed files with 3 additions and 4 deletions

View File

@@ -1,14 +1,12 @@
import { IpcMainEvent } from "electron"; import { IpcMainEvent } from "electron";
import Store from "../store/store";
import { User } from "firebase/auth"; import { User } from "firebase/auth";
import log from "electron-log/main"; import Store from "../store/store";
const ipcMainHandleAuthStateChanged = async ( const ipcMainHandleAuthStateChanged = async (
event: IpcMainEvent, event: IpcMainEvent,
user: User | null user: User | null
) => { ) => {
Store.set("user", user); Store.set("user", user);
log.log(Store.get("user"));
}; };
export { ipcMainHandleAuthStateChanged }; export { ipcMainHandleAuthStateChanged };

View File

@@ -1,5 +1,6 @@
import Store from "electron-store"; // @ts-nocheck
const Store = require("electron-store").default;
const store = new Store({ const store = new Store({
defaults: { defaults: {
filePaths: [], filePaths: [],