1
0
mirror of https://github.com/sasjs/server.git synced 2025-12-10 11:24:35 +00:00

chore: quick fix

This commit is contained in:
Saad Jutt
2022-07-05 05:30:13 +05:00
parent 7edb47a4cb
commit 1108d3dd7b

View File

@@ -21,10 +21,14 @@ export const getAuthorizedRoutes = () => {
export const getUri = (req: Request) => {
const { baseUrl, path: reqPath } = req
const appStream = reqPath.split('/')[1]
if (baseUrl === '/AppStream') {
const appStream = reqPath.split('/')[1]
// removing trailing slash of URLs
return (baseUrl + '/' + appStream).replace(/\/$/, '')
// removing trailing slash of URLs
return (baseUrl + '/' + appStream).replace(/\/$/, '')
}
return baseUrl + reqPath
}
export const isAuthorizingRoute = (req: Request): boolean =>