Skip to content

Commit d1b15da

Browse files
committed
Fixing some format issues
1 parent 55e3ff6 commit d1b15da

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

lib/handlers/get.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,8 @@ function handler (req, res, next) {
8787
let mimeTypeByExt = mime.lookup(_path.basename(path))
8888
let isHtmlResource = mimeTypeByExt && mimeTypeByExt.includes('html')
8989
let useDataBrowser = ldp.dataBrowserPath && (
90-
container ||
91-
RDFs.includes(contentType) && !isHtmlResource && !ldp.suppressDataBrowser)
90+
container ||
91+
RDFs.includes(contentType) && !isHtmlResource && !ldp.suppressDataBrowser)
9292

9393
if (useDataBrowser) {
9494
res.set('Content-Type', 'text/html')
@@ -162,7 +162,7 @@ function globHandler (req, res, next) {
162162
debugGlob('found matches ' + matches)
163163
Promise.all(matches.map(match => new Promise((resolve, reject) => {
164164
const baseUri = reqOrigin + '/' + match.substr(root.length)
165-
fs.readFile(match, { encoding: 'utf8' }, function (err, fileData) {
165+
fs.readFile(match, {encoding: 'utf8'}, function (err, fileData) {
166166
if (err) {
167167
debugGlob('error ' + err)
168168
return resolve()
@@ -184,15 +184,15 @@ function globHandler (req, res, next) {
184184
})
185185
})
186186
})))
187-
.then(() => {
188-
const data = $rdf.serialize(undefined, globGraph, requestUri, 'text/turtle')
189-
// TODO this should be added as a middleware in the routes
190-
res.setHeader('Content-Type', 'text/turtle')
191-
debugGlob('returning turtle')
192-
193-
res.send(data)
194-
return next()
195-
})
187+
.then(() => {
188+
const data = $rdf.serialize(undefined, globGraph, requestUri, 'text/turtle')
189+
// TODO this should be added as a middleware in the routes
190+
res.setHeader('Content-Type', 'text/turtle')
191+
debugGlob('returning turtle')
192+
193+
res.send(data)
194+
return next()
195+
})
196196
})
197197
}
198198

0 commit comments

Comments
 (0)