diff options
Diffstat (limited to 'src/server/server_Initialization.ts')
-rw-r--r-- | src/server/server_Initialization.ts | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/server/server_Initialization.ts b/src/server/server_Initialization.ts index 641a88312..5deb66caf 100644 --- a/src/server/server_Initialization.ts +++ b/src/server/server_Initialization.ts @@ -21,6 +21,7 @@ import { Database } from './database'; import { WebSocket } from './websocket'; import axios from 'axios'; import { JSDOM } from 'jsdom'; +import { setupDynamicToolsAPI } from './api/dynamicTools'; /* RouteSetter is a wrapper around the server that prevents the server from being exposed. */ @@ -213,6 +214,10 @@ export default async function InitializeServer(routeSetter: RouteSetter) { // app.use(cors({ origin: (_origin: any, callback: any) => callback(null, true) })); registerAuthenticationRoutes(app); // this adds routes to authenticate a user (login, etc) registerCorsProxy(app); // this adds a /corsproxy/ route to allow clients to get to urls that would otherwise be blocked by cors policies + + // Set up the dynamic tools API + setupDynamicToolsAPI(app); + isRelease && !SSL.Loaded && SSL.exit(); routeSetter(new RouteManager(app, isRelease)); // this sets up all the regular supervised routes (things like /home, download/upload api's, pdf, search, session, etc) isRelease && process.env.serverPort && (resolvedPorts.server = Number(process.env.serverPort)); |