From ffbe18a253051b0ec6435bcf0f955ce8bcce100d Mon Sep 17 00:00:00 2001 From: krishna Date: Tue, 23 Aug 2016 20:33:41 +0530 Subject: [PATCH] fix/fetch_file_metadata: resolve fetching file with metadata via dns fixes #234 --- app/server/controllers/dns.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/server/controllers/dns.js b/app/server/controllers/dns.js index d9be6fc1..c151f41e 100644 --- a/app/server/controllers/dns.js +++ b/app/server/controllers/dns.js @@ -122,7 +122,7 @@ export var getFile = function(req, res, next) { 'Content-Type': mime.lookup(filePath) || 'application/octet-stream' }; if (fileStats.metadata && fileStats.metadata.length > 0) { - headers.metadata = new Buffer(fileStats.metadata, 'base64').tostring('base64'); + headers.metadata = new Buffer(fileStats.metadata, 'base64').toString('base64'); } res.writeHead(range ? 206 : 200, headers); if (chunksize === 0) {