UNPKG

@practicaloptimism/uniplexer

Version:

A multiplexer for 3rd party service providers and application protocols

19 lines (13 loc) 431 B
import { GetItem } from '../../../@utility/data-structures/database' import { storeTable } from '../variables' import { createItemStore } from './create-item-store' const getItem: GetItem = getItemFunction async function getItemFunction (storeId: string, itemId: string): Promise<any[]> { if (!storeTable[storeId]) { await createItemStore(storeId) } return storeTable[storeId].getItem(itemId) } export { getItem }