|
@@ -7,7 +7,6 @@ const logger = loggerFactory('growi:routes:attachment');
|
|
|
|
|
|
|
|
const { serializePageSecurely } = require('../models/serializers/page-serializer');
|
|
const { serializePageSecurely } = require('../models/serializers/page-serializer');
|
|
|
const { serializeRevisionSecurely } = require('../models/serializers/revision-serializer');
|
|
const { serializeRevisionSecurely } = require('../models/serializers/revision-serializer');
|
|
|
-
|
|
|
|
|
const ApiResponse = require('../util/apiResponse');
|
|
const ApiResponse = require('../util/apiResponse');
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -229,6 +228,7 @@ module.exports = function(crowi, app) {
|
|
|
res.set({
|
|
res.set({
|
|
|
ETag: `Attachment-${attachment._id}`,
|
|
ETag: `Attachment-${attachment._id}`,
|
|
|
'Last-Modified': attachment.createdAt.toUTCString(),
|
|
'Last-Modified': attachment.createdAt.toUTCString(),
|
|
|
|
|
+ 'Content-Length': attachment.fileSize,
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
// download
|
|
// download
|