MCPcopy Index your code
hub / github.com/nodeSolidServer/node-solid-server / contentForNew

Function contentForNew

lib/handlers/patch.mjs:33–38  ·  view source on GitHub ↗
(contentType)

Source from the content-addressed store, hash-verified

31}
32
33function contentForNew (contentType) {
34 let contentForNew = ''
35 if (contentType.includes('ld+json')) contentForNew = JSON.stringify('{}')
36 else if (contentType.includes('rdf+xml')) contentForNew = '<rdf:RDF\n xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">\n\n</rdf:RDF>'
37 return contentForNew
38}
39
40// Handles a PATCH request
41async function patchHandler (req, res, next) {

Callers 1

readGraphFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected