0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-16 21:56:25 -05:00

fix: refactor #268 in a better way, amended to elegant way

This commit is contained in:
Juan Picado @jotadeveloper 2017-07-29 12:03:51 +02:00
parent fdc9624d70
commit 94fb6adf4f
No known key found for this signature in database
GPG key ID: 18AC54485952D158

View file

@ -14,7 +14,11 @@ const encode = function(thing) {
return encodeURIComponent(thing).replace(/^%40/, '@'); return encodeURIComponent(thing).replace(/^%40/, '@');
}; };
const contenTypeAccept = 'application/octet-stream, application/vnd.npm.install-v1+json; q=1.0, application/json; q=0.8, */*'; const contenTypeAccept = [
'application/octet-stream',
'application/vnd.npm.install-v1+json; q=1.0',
'application/json; q=0.8, */*',
].join(', ');
/** /**
* Just a helper (`config[key] || default` doesn't work because of zeroes) * Just a helper (`config[key] || default` doesn't work because of zeroes)