mirror of
https://github.com/wassname/talk.git
synced 2026-07-19 11:28:50 +08:00
fix: allowed client router to take over routing past the mount point (#2086)
This commit is contained in:
@@ -28,9 +28,11 @@ export function createClientTargetRouter({
|
||||
// Create a router.
|
||||
const router = express.Router();
|
||||
|
||||
// Always send the cache headers.
|
||||
router.use(cacheHeadersMiddleware(cacheDuration));
|
||||
|
||||
router.get("/", (req, res) => res.render(view, { staticURI }));
|
||||
// Wildcard display all the client routes under the provided prefix.
|
||||
router.get("/*", (req, res) => res.render(view, { staticURI }));
|
||||
|
||||
return router;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user