From 601f0ea671e9f84dd38b70e3d4aaa40e0ec923fb Mon Sep 17 00:00:00 2001 From: Mononaut Date: Fri, 17 Jan 2025 06:03:12 +0000 Subject: [PATCH] fetch custom dash config from services --- backend/src/api/services/services-routes.ts | 6 ++++++ frontend/src/index.mempool.html | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/backend/src/api/services/services-routes.ts b/backend/src/api/services/services-routes.ts index 520496249..d149cd629 100644 --- a/backend/src/api/services/services-routes.ts +++ b/backend/src/api/services/services-routes.ts @@ -7,6 +7,7 @@ class ServicesRoutes { public initRoutes(app: Application): void { app .get(config.MEMPOOL.API_URL_PREFIX + 'wallet/:walletId', this.$getWallet) + .get(config.MEMPOOL.API_URL_PREFIX + 'services/custom/config', this.$getCustomConfig) ; } @@ -22,6 +23,11 @@ class ServicesRoutes { handleError(req, res, 500, 'Failed to get wallet'); } } + + // serve a blank custom config file by default + private async $getCustomConfig(req: Request, res: Response): Promise { + res.status(200).contentType('application/javascript').send(''); + } } export default new ServicesRoutes(); diff --git a/frontend/src/index.mempool.html b/frontend/src/index.mempool.html index ed5f7e0b4..b5ef85feb 100644 --- a/frontend/src/index.mempool.html +++ b/frontend/src/index.mempool.html @@ -5,7 +5,7 @@ mempool - Bitcoin Explorer - +