mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-06-26 17:45:49 +02:00
refactor(auth): remove unused SSO provider retrieval logic
- Deleted the import statement for `getSSOProviders` and the associated logic for fetching issuer origins from SSO providers. - This cleanup improves code clarity by removing unnecessary dependencies and streamlining the trusted origins configuration.
This commit is contained in:
@@ -10,7 +10,6 @@ import { IS_CLOUD } from "../constants";
|
||||
import { db } from "../db";
|
||||
import * as schema from "../db/schema";
|
||||
import { getUserByToken } from "../services/admin";
|
||||
import { getSSOProviders } from "../services/proprietary/sso";
|
||||
import {
|
||||
getWebServerSettings,
|
||||
updateWebServerSettings,
|
||||
@@ -50,14 +49,9 @@ const { handler, api } = betterAuth({
|
||||
if (!settings) {
|
||||
return [];
|
||||
}
|
||||
|
||||
const providers = await getSSOProviders();
|
||||
const issuerOrigins = providers.map((provider) => provider.issuer);
|
||||
|
||||
return [
|
||||
...(settings?.serverIp ? [`http://${settings?.serverIp}:3000`] : []),
|
||||
...(settings?.host ? [`https://${settings?.host}`] : []),
|
||||
...issuerOrigins,
|
||||
...(process.env.NODE_ENV === "development"
|
||||
? [
|
||||
"http://localhost:3000",
|
||||
|
||||
Reference in New Issue
Block a user