Skip to content

Commit 00a5468

Browse files
committed
Split imports
1 parent 69c01c8 commit 00a5468

File tree

15 files changed

+42
-48
lines changed

15 files changed

+42
-48
lines changed

apps/meteor/client/lib/customOAuth/CustomOAuth.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { OAuth } from 'meteor/oauth';
77

88
import { isURL } from '../../../lib/utils/isURL';
99
import type { IOAuthProvider } from '../../definitions/IOAuthProvider';
10-
import { createOAuthTotpLoginMethod } from '../../meteor/overrides/login/oauth';
10+
import { createOAuthTotpLoginMethod } from '../../meteor/login/oauth';
1111
import { overrideLoginMethod, type LoginCallback } from '../2fa/overrideLoginMethod';
1212
import { loginServices } from '../loginServices';
1313
import { CustomOAuthError } from './CustomOAuthError';

apps/meteor/client/main.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,9 @@
1-
import './meteor/overrides/desktopInjection';
2-
import './meteor/overrides/ddpOverREST';
3-
import './meteor/overrides/oauthRedirectUri';
4-
import './meteor/overrides/settings';
5-
import './meteor/overrides/totpOnCall';
6-
import './meteor/overrides/unstoreLoginToken';
7-
import './meteor/overrides/userAndUsers';
1+
import './meteor/overrides';
82
import './meteor/startup';
93
import './serviceWorker';
104

115
import('@rocket.chat/fuselage-polyfills')
12-
.then(() => import('./meteor/overrides'))
6+
.then(() => import('./meteor/login'))
137
.then(() => import('./ecdh'))
148
.then(() => import('./importPackages'))
159
.then(() => import('./startup'))

apps/meteor/client/meteor/overrides/login/cas.ts renamed to apps/meteor/client/meteor/login/cas.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { Random } from '@rocket.chat/random';
22
import { Meteor } from 'meteor/meteor';
33

4-
import { callLoginMethod } from '../../../lib/2fa/overrideLoginMethod';
4+
import { callLoginMethod } from '../../lib/2fa/overrideLoginMethod';
55

66
declare module 'meteor/meteor' {
77
// eslint-disable-next-line @typescript-eslint/no-namespace
@@ -12,7 +12,7 @@ declare module 'meteor/meteor' {
1212

1313
Meteor.loginWithCas = (_, callback) => {
1414
const credentialToken = Random.id();
15-
import('../../../lib/openCASLoginPopup')
15+
import('../../lib/openCASLoginPopup')
1616
.then(({ openCASLoginPopup }) => openCASLoginPopup(credentialToken))
1717
.then(() => callLoginMethod({ methodArguments: [{ cas: { credentialToken } }] }))
1818
.then(() => callback?.())

apps/meteor/client/meteor/overrides/login/crowd.ts renamed to apps/meteor/client/meteor/login/crowd.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Meteor } from 'meteor/meteor';
22

3-
import { callLoginMethod, handleLogin, type LoginCallback } from '../../../lib/2fa/overrideLoginMethod';
3+
import { callLoginMethod, handleLogin, type LoginCallback } from '../../lib/2fa/overrideLoginMethod';
44

55
declare module 'meteor/meteor' {
66
// eslint-disable-next-line @typescript-eslint/no-namespace

apps/meteor/client/meteor/overrides/login/facebook.ts renamed to apps/meteor/client/meteor/login/facebook.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import { Meteor } from 'meteor/meteor';
77
import { OAuth } from 'meteor/oauth';
88

99
import { createOAuthTotpLoginMethod } from './oauth';
10-
import { overrideLoginMethod } from '../../../lib/2fa/overrideLoginMethod';
11-
import { wrapRequestCredentialFn } from '../../../lib/wrapRequestCredentialFn';
10+
import { overrideLoginMethod } from '../../lib/2fa/overrideLoginMethod';
11+
import { wrapRequestCredentialFn } from '../../lib/wrapRequestCredentialFn';
1212

1313
const { loginWithFacebook } = Meteor;
1414
const loginWithFacebookAndTOTP = createOAuthTotpLoginMethod(Facebook);

apps/meteor/client/meteor/overrides/login/github.ts renamed to apps/meteor/client/meteor/login/github.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import { Meteor } from 'meteor/meteor';
77
import { OAuth } from 'meteor/oauth';
88

99
import { createOAuthTotpLoginMethod } from './oauth';
10-
import { overrideLoginMethod } from '../../../lib/2fa/overrideLoginMethod';
11-
import { wrapRequestCredentialFn } from '../../../lib/wrapRequestCredentialFn';
10+
import { overrideLoginMethod } from '../../lib/2fa/overrideLoginMethod';
11+
import { wrapRequestCredentialFn } from '../../lib/wrapRequestCredentialFn';
1212

1313
const { loginWithGithub } = Meteor;
1414
const loginWithGithubAndTOTP = createOAuthTotpLoginMethod(Github);

apps/meteor/client/meteor/overrides/login/google.ts renamed to apps/meteor/client/meteor/login/google.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import { Meteor } from 'meteor/meteor';
77
import { OAuth } from 'meteor/oauth';
88

99
import { createOAuthTotpLoginMethod } from './oauth';
10-
import { overrideLoginMethod, type LoginCallback } from '../../../lib/2fa/overrideLoginMethod';
11-
import { wrapRequestCredentialFn } from '../../../lib/wrapRequestCredentialFn';
10+
import { overrideLoginMethod, type LoginCallback } from '../../lib/2fa/overrideLoginMethod';
11+
import { wrapRequestCredentialFn } from '../../lib/wrapRequestCredentialFn';
1212

1313
declare module 'meteor/meteor' {
1414
// eslint-disable-next-line @typescript-eslint/no-namespace
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import './cas';
2+
import './crowd';
3+
import './facebook';
4+
import './github';
5+
import './google';
6+
import './ldap';
7+
import './meteorDeveloperAccount';
8+
import './oauth';
9+
import './password';
10+
import './saml';
11+
import './twitter';

apps/meteor/client/meteor/overrides/login/ldap.ts renamed to apps/meteor/client/meteor/login/ldap.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Meteor } from 'meteor/meteor';
22

3-
import { callLoginMethod, handleLogin, type LoginCallback } from '../../../lib/2fa/overrideLoginMethod';
3+
import { callLoginMethod, handleLogin, type LoginCallback } from '../../lib/2fa/overrideLoginMethod';
44

55
declare module 'meteor/meteor' {
66
// eslint-disable-next-line @typescript-eslint/no-namespace

apps/meteor/client/meteor/overrides/login/meteorDeveloperAccount.ts renamed to apps/meteor/client/meteor/login/meteorDeveloperAccount.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import { MeteorDeveloperAccounts } from 'meteor/meteor-developer-oauth';
55
import { OAuth } from 'meteor/oauth';
66

77
import { createOAuthTotpLoginMethod } from './oauth';
8-
import { overrideLoginMethod } from '../../../lib/2fa/overrideLoginMethod';
9-
import { wrapRequestCredentialFn } from '../../../lib/wrapRequestCredentialFn';
8+
import { overrideLoginMethod } from '../../lib/2fa/overrideLoginMethod';
9+
import { wrapRequestCredentialFn } from '../../lib/wrapRequestCredentialFn';
1010

1111
const { loginWithMeteorDeveloperAccount } = Meteor;
1212
const loginWithMeteorDeveloperAccountAndTOTP = createOAuthTotpLoginMethod(MeteorDeveloperAccounts);

0 commit comments

Comments
 (0)