This commit is contained in:
Manav Rathi 2024-04-18 09:23:03 +05:30
parent 7bf5c0ad5c
commit dedc2f8585
No known key found for this signature in database
4 changed files with 7 additions and 7 deletions

View file

@ -2,7 +2,7 @@ import { safeStorage } from "electron/main";
import { keysStore } from "../stores/keys.store";
import { safeStorageStore } from "../stores/safeStorage.store";
import { uploadStatusStore } from "../stores/upload.store";
import { watchStore } from "../stores/watch.store";
import { watchStore } from "../stores/watch";
export const clearStores = () => {
uploadStatusStore.clear();

View file

@ -3,7 +3,7 @@ import ElectronLog from "electron-log";
import fs from "node:fs/promises";
import path from "node:path";
import { FolderWatch, WatchStoreType } from "../../types/ipc";
import { watchStore } from "../stores/watch.store";
import { watchStore } from "../stores/watch";
export const findFiles = async (dirPath: string) => {
const items = await fs.readdir(dirPath, { withFileTypes: true });

View file

@ -1,5 +1,9 @@
import Store, { Schema } from "electron-store";
import { WatchStoreType } from "../../types/ipc";
import { type FolderWatch } from "../../types/ipc";
interface WatchStoreSchema {
mappings: FolderWatch[];
}
const watchStoreSchema: Schema<WatchStoreType> = {
mappings: {

View file

@ -66,10 +66,6 @@ export interface ElectronFile {
arrayBuffer: () => Promise<Uint8Array>;
}
export interface WatchStoreType {
mappings: FolderWatch[];
}
export enum FILE_PATH_TYPE {
/* eslint-disable no-unused-vars */
FILES = "files",