From c8b5dc269a43ebb5e23122dc68e525a849bafe0c Mon Sep 17 00:00:00 2001 From: SamTV12345 <40429738+samtv12345@users.noreply.github.com> Date: Tue, 1 Oct 2024 21:24:47 +0200 Subject: [PATCH] Fixed export. --- src/node/hooks/express/importexport.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/node/hooks/express/importexport.ts b/src/node/hooks/express/importexport.ts index bc8a04070..3a361d005 100644 --- a/src/node/hooks/express/importexport.ts +++ b/src/node/hooks/express/importexport.ts @@ -25,8 +25,8 @@ exports.expressCreateServer = (hookName:string, args:ArgsExpressType, cb:Functio }); // handle export requests - args.app.use('/p/:pad/:rev{.:ext}/export/:type', limiter); - args.app.get('/p/:pad/:rev{.:ext}/export/:type', (req:any, res:any, next:Function) => { + args.app.use('/p/:pad{/:rev}/export/:type', limiter); + args.app.get('/p/:pad{/:rev}/export/:type', (req:any, res:any, next:Function) => { (async () => { const types = ['pdf', 'doc', 'txt', 'html', 'odt', 'etherpad']; // send a 404 if we don't support this filetype