import { DeleteItem } from '../../../@utility/data-structures/database' import { storeTable } from '../variables' const deleteItem: DeleteItem = deleteItemFunction async function deleteItemFunction (storeId: string, itemId: string): Promise { let hasError = false if (!storeTable[storeId]) { return [false] } await storeTable[storeId].removeItem(itemId, (err: any) => { hasError = err ? true : false }) return [hasError] } export { deleteItem }