mirror of
https://github.com/sasjs/server.git
synced 2026-01-04 21:30:05 +00:00
test: fixed specs
This commit is contained in:
@@ -7,14 +7,15 @@ const webRouter = express.Router()
|
||||
const controller = new WebController()
|
||||
|
||||
webRouter.get('/', async (req, res) => {
|
||||
let response
|
||||
try {
|
||||
const response = await controller.home()
|
||||
|
||||
response = await controller.home()
|
||||
} catch (_) {
|
||||
response = 'Web Build is not present'
|
||||
} finally {
|
||||
res.cookie('XSRF-TOKEN', req.csrfToken())
|
||||
|
||||
return res.send(response)
|
||||
} catch (_) {
|
||||
return res.send('Web Build is not present')
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user