mirror of
https://github.com/azures04/crafatar.git
synced 2026-03-21 23:41:18 +01:00
remove 'public' part from Cache-Control, not required
This commit is contained in:
parent
5654d51eec
commit
29fa734148
@ -29,7 +29,7 @@ module.exports = function(request, response, result) {
|
|||||||
// These headers are the same for every response
|
// These headers are the same for every response
|
||||||
var headers = {
|
var headers = {
|
||||||
"Content-Type": result.body && result.type || "text/plain",
|
"Content-Type": result.body && result.type || "text/plain",
|
||||||
"Cache-Control": "max-age=" + config.caching.browser + ", public",
|
"Cache-Control": "max-age=" + config.caching.browser,
|
||||||
"Response-Time": Date.now() - request.start,
|
"Response-Time": Date.now() - request.start,
|
||||||
"X-Request-ID": request.id,
|
"X-Request-ID": request.id,
|
||||||
"Access-Control-Allow-Origin": "*"
|
"Access-Control-Allow-Origin": "*"
|
||||||
|
|||||||
@ -222,7 +222,7 @@ describe("Crafatar", function() {
|
|||||||
assert("" + res.headers["response-time"]);
|
assert("" + res.headers["response-time"]);
|
||||||
assert(res.headers["x-request-id"]);
|
assert(res.headers["x-request-id"]);
|
||||||
assert.equal(res.headers["access-control-allow-origin"], "*");
|
assert.equal(res.headers["access-control-allow-origin"], "*");
|
||||||
assert.equal(res.headers["cache-control"], "max-age=" + config.caching.browser + ", public");
|
assert.equal(res.headers["cache-control"], "max-age=" + config.caching.browser);
|
||||||
}
|
}
|
||||||
|
|
||||||
// throws Exception when +url+ is requested with +etag+
|
// throws Exception when +url+ is requested with +etag+
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user