UNPKG

unleash-server

Version:

Unleash is an enterprise ready feature flag service. It provides different strategies for handling feature flags.

13 lines 922 B
import { InactiveUsersService } from './inactive-users-service.js'; import { InactiveUsersStore } from './inactive-users-store.js'; import { FakeInactiveUsersStore } from './fakes/fake-inactive-users-store.js'; export const createInactiveUsersService = (db, config, userService) => { const { eventBus, getLogger, userInactivityThresholdInDays } = config; const inactiveUsersStore = new InactiveUsersStore(db, eventBus, getLogger); return new InactiveUsersService({ inactiveUsersStore }, { getLogger, userInactivityThresholdInDays }, { userService }); }; export const createFakeInactiveUsersService = ({ getLogger, userInactivityThresholdInDays, }, userService) => { const fakeStore = new FakeInactiveUsersStore(); return new InactiveUsersService({ inactiveUsersStore: fakeStore }, { getLogger, userInactivityThresholdInDays }, { userService }); }; //# sourceMappingURL=createInactiveUsersService.js.map