Skip to content

Commit

Permalink
removed comments
Browse files Browse the repository at this point in the history
  • Loading branch information
christian-hawk committed Jun 1, 2020
1 parent 93a6a1f commit b9dbad5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,15 @@ router.get('/auth/meta/idp/:idp',
fs.readFile(safeFileFullPath,
(err, data) => {
if (err) {
// Handle ENOENT error

if (!fs.existsSync(safeFileFullPath)){
// ENOENT ERROR
EnoentError = `Requested metadata for ${MetaFileNameNoExt} not found`
logger.log2('error',EnoentError)
res.status(404).send(EnoentError)
}
res.status(500).send(`An error occurred: ${err}`)
logger.log2('error',err)

} else {
res.status(200).set('Content-Type', 'text/xml').send(String(data))
}
Expand Down

0 comments on commit b9dbad5

Please sign in to comment.