mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2025-04-01 20:24:18 +02:00
Passing url query to redirects
This commit is contained in:
@@ -119,15 +119,15 @@ function GetApp() {
|
||||
from: '/menuClick',
|
||||
to: '/',
|
||||
},
|
||||
{
|
||||
from: '/lred',
|
||||
to: '/allQuestions.html',
|
||||
},
|
||||
{
|
||||
// to be backwards compatible
|
||||
from: '/legacy',
|
||||
to: '/allQuestions.html',
|
||||
},
|
||||
{
|
||||
from: '/lred',
|
||||
to: '/allQuestions',
|
||||
},
|
||||
{
|
||||
from: '/allqr',
|
||||
to: 'http://api.frylabs.net/allqr.txt',
|
||||
@@ -153,7 +153,13 @@ function GetApp() {
|
||||
logger.LogReq(req)
|
||||
}
|
||||
logger.DebugLog(`Qmining module ${redirect.from} redirect`, 'infos', 1)
|
||||
res.redirect(`${redirect.to}`)
|
||||
|
||||
res.redirect(
|
||||
url.format({
|
||||
pathname: `${redirect.to}`,
|
||||
query: req.query,
|
||||
})
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
|
Submodule submodules/qmining-page updated: 36a564498b...96a44e3171
Reference in New Issue
Block a user