solid-server 5.7.0 → 5.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/create-app.js CHANGED
@@ -32,7 +32,7 @@ const corsSettings = cors({
32
32
  methods: [
33
33
  'OPTIONS', 'HEAD', 'GET', 'PATCH', 'POST', 'PUT', 'DELETE'
34
34
  ],
35
- exposedHeaders: 'Authorization, User, Location, Link, Vary, Last-Modified, ETag, Accept-Patch, Accept-Post, Updates-Via, Allow, WAC-Allow, Content-Length, WWW-Authenticate, X-Powered-By',
35
+ exposedHeaders: 'Authorization, User, Location, Link, Vary, Last-Modified, ETag, Accept-Patch, Accept-Post, Updates-Via, Allow, WAC-Allow, Content-Length, WWW-Authenticate, MS-Author-Via, X-Powered-By',
36
36
  credentials: true,
37
37
  maxAge: 1728000,
38
38
  origin: true,
@@ -13,7 +13,7 @@ const validUrl = require('valid-url')
13
13
 
14
14
  const CORS_SETTINGS = {
15
15
  methods: 'GET',
16
- exposedHeaders: 'Authorization, User, Location, Link, Vary, Last-Modified, Content-Length, Content-Location, X-Powered-By',
16
+ exposedHeaders: 'Authorization, User, Location, Link, Vary, Last-Modified, Content-Length, Content-Location, MS-Author-Via, X-Powered-By',
17
17
  maxAge: 1728000,
18
18
  origin: true
19
19
  }
@@ -27,6 +27,8 @@ async function handler (req, res, next) {
27
27
  const requestedType = negotiator.mediaType()
28
28
  const possibleRDFType = negotiator.mediaType(RDFs)
29
29
 
30
+ res.header('MS-Author-Via', 'SPARQL')
31
+
30
32
  // Set live updates
31
33
  if (ldp.live) {
32
34
  res.header('Updates-Via', ldp.resourceMapper.resolveUrl(req.hostname).replace(/^http/, 'ws'))
@@ -23,6 +23,7 @@ const DEFAULT_FOR_NEW_CONTENT_TYPE = 'text/turtle'
23
23
  // Handles a PATCH request
24
24
  async function patchHandler (req, res, next) {
25
25
  debug(`PATCH -- ${req.originalUrl}`)
26
+ res.header('MS-Author-Via', 'SPARQL')
26
27
  try {
27
28
  // Obtain details of the target resource
28
29
  const ldp = req.app.locals.ldp
@@ -8,6 +8,7 @@ const { stringToStream } = require('../utils')
8
8
 
9
9
  async function handler (req, res, next) {
10
10
  debug(req.originalUrl)
11
+ res.header('MS-Author-Via', 'SPARQL')
11
12
 
12
13
  const contentType = req.get('content-type')
13
14
  if (isAuxiliary(req)) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "solid-server",
3
3
  "description": "Solid server on top of the file-system",
4
- "version": "5.7.0",
4
+ "version": "5.7.1",
5
5
  "author": {
6
6
  "name": "Tim Berners-Lee",
7
7
  "email": "timbl@w3.org"