diff options
Diffstat (limited to 'server/lib/auth')
-rw-r--r-- | server/lib/auth/oauth-model.ts | 1 | ||||
-rw-r--r-- | server/lib/auth/oauth.ts | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/server/lib/auth/oauth-model.ts b/server/lib/auth/oauth-model.ts index f2ef0a78a..b68cce6d2 100644 --- a/server/lib/auth/oauth-model.ts +++ b/server/lib/auth/oauth-model.ts | |||
@@ -226,6 +226,7 @@ async function createUserFromExternal (pluginAuth: string, options: { | |||
226 | password: null, | 226 | password: null, |
227 | email: options.email, | 227 | email: options.email, |
228 | nsfwPolicy: CONFIG.INSTANCE.DEFAULT_NSFW_POLICY, | 228 | nsfwPolicy: CONFIG.INSTANCE.DEFAULT_NSFW_POLICY, |
229 | p2pEnabled: CONFIG.DEFAULTS.P2P.WEBAPP.ENABLED, | ||
229 | autoPlayVideo: true, | 230 | autoPlayVideo: true, |
230 | role: options.role, | 231 | role: options.role, |
231 | videoQuota: CONFIG.USER.VIDEO_QUOTA, | 232 | videoQuota: CONFIG.USER.VIDEO_QUOTA, |
diff --git a/server/lib/auth/oauth.ts b/server/lib/auth/oauth.ts index 497773536..2bf7a6361 100644 --- a/server/lib/auth/oauth.ts +++ b/server/lib/auth/oauth.ts | |||
@@ -8,8 +8,9 @@ import { | |||
8 | UnauthorizedClientError, | 8 | UnauthorizedClientError, |
9 | UnsupportedGrantTypeError | 9 | UnsupportedGrantTypeError |
10 | } from 'oauth2-server' | 10 | } from 'oauth2-server' |
11 | import { randomBytesPromise, sha1 } from '@server/helpers/core-utils' | 11 | import { randomBytesPromise } from '@server/helpers/core-utils' |
12 | import { MOAuthClient } from '@server/types/models' | 12 | import { MOAuthClient } from '@server/types/models' |
13 | import { sha1 } from '@shared/extra-utils' | ||
13 | import { OAUTH_LIFETIME } from '../../initializers/constants' | 14 | import { OAUTH_LIFETIME } from '../../initializers/constants' |
14 | import { BypassLogin, getClient, getRefreshToken, getUser, revokeToken, saveToken } from './oauth-model' | 15 | import { BypassLogin, getClient, getRefreshToken, getUser, revokeToken, saveToken } from './oauth-model' |
15 | 16 | ||