import type { IpcMainEvent, IpcMainInvokeEvent } from 'electron' import { IRPCActionType, IToolboxItemType } from '~/universal/types/enum' export const sendToolboxResWithType = (type: IToolboxItemType) => (event: IpcMainEvent | IpcMainInvokeEvent, res?: Omit) => { return event.sender.send(IRPCActionType.TOOLBOX_CHECK_RES, { ...res, type }) }