1 import { all } from 'redux-saga/effects';
3 import type { PassSaga, RootSagaOptions } from '@proton/pass/store/types';
5 import aliasContactSagas from './alias/alias-contact.sagas';
6 import aliasDetailsRequest from './alias/alias-details-request.saga';
7 import aliasManagementSagas from './alias/alias-management.sagas';
8 import aliasOptionsRequest from './alias/alias-options-request.saga';
9 import aliasSyncSagas from './alias/alias-sync.sagas';
10 import customDomainsSagas from './alias/custom-domains.sagas';
11 import lockCreate from './auth/lock-create.saga';
12 import lock from './auth/lock.saga';
13 import passwordConfirm from './auth/password-confirm.saga';
14 import passwordExtra from './auth/password-extra.saga';
15 import ssoSagas from './auth/sso.sagas';
16 import unlock from './auth/unlock.saga';
17 import boot from './client/boot.saga';
18 import cache from './client/cache.saga';
19 import notification from './client/notification.saga';
20 import reportProblem from './client/report-problem.saga';
21 import settings from './client/settings.saga';
22 import sync from './client/sync.saga';
23 import events from './events/events.saga';
24 import itemsImport from './import/import.saga';
25 import inviteAccept from './invites/invite-accept.saga';
26 import inviteAddressesValidate from './invites/invite-addresses-validate.saga';
27 import inviteCreate from './invites/invite-create.saga';
28 import inviteRecommendations from './invites/invite-recommendations.saga';
29 import inviteReject from './invites/invite-reject.saga';
30 import inviteRemove from './invites/invite-remove.saga';
31 import inviteResend from './invites/invite-resend.saga';
32 import newUserInvitePromote from './invites/new-user-invite-promote.saga';
33 import newUserInviteRemove from './invites/new-user-invite-remove.saga';
34 import itemBulkDelete from './items/item-bulk-delete.saga';
35 import itemBulkMove from './items/item-bulk-move.saga';
36 import itemBulkRestore from './items/item-bulk-restore.saga';
37 import itemBulkTrash from './items/item-bulk-trash.saga';
38 import itemCreation from './items/item-creation.saga';
39 import itemDelete from './items/item-delete.saga';
40 import itemEdit from './items/item-edit.saga';
41 import itemHistory from './items/item-history.saga';
42 import itemMove from './items/item-move.saga';
43 import itemPin from './items/item-pin.saga';
44 import itemRestore from './items/item-restore.saga';
45 import itemTrash from './items/item-trash.saga';
46 import itemUnpin from './items/item-unpin.saga';
47 import itemSetFlags from './items/item.set-flags.saga';
48 import getOrganizationSettings from './organization/organization-settings.saga';
49 import secureLinkSagas from './secure-links/secure-links.sagas';
50 import shareAccessSagas from './shares/share-access.saga';
51 import shareEditRole from './shares/share-edit-role.saga';
52 import shareLeave from './shares/share-leave.saga';
53 import shareRemoveMember from './shares/share-remove-member.saga';
54 import featureFlags from './user/feature-flags.saga';
55 import userAccess from './user/user-access.saga';
56 import userSettings from './user/user-settings.saga';
57 import trashDelete from './vaults/trash-empty.saga';
58 import trashRestore from './vaults/trash-restore.saga';
59 import vaultCreation from './vaults/vault-creation.saga';
60 import vaultDelete from './vaults/vault-delete.saga';
61 import vaultEdit from './vaults/vault-edit.saga';
62 import vaultMoveAllItems from './vaults/vault-move-all-items.saga';
63 import vaultTransferOwner from './vaults/vault-transfer-owner.saga';
65 const COMMON_SAGAS = [
67 ...aliasManagementSagas,
69 ...customDomainsSagas,
79 getOrganizationSettings,
81 inviteAddressesValidate,
83 inviteRecommendations,
104 newUserInvitePromote,
127 export const rootSagaFactory = (platformSagas: PassSaga[]) =>
128 function* workerRootSaga(options: RootSagaOptions) {
129 yield all(COMMON_SAGAS.concat(platformSagas).map((saga) => saga(options)));