0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2025-01-27 22:59:51 -05:00

Fixed sinopia to allow old tarballs with @ in them

This commit is contained in:
Joseph Gentle 2014-05-15 16:07:33 -07:00
parent a79fa68deb
commit 21f7f03cf7

View file

@ -10,8 +10,7 @@ module.exports.validate_name = function(name) {
if ( if (
name.charAt(0) === '.' || // ".bin", etc. name.charAt(0) === '.' || // ".bin", etc.
name.charAt(0) === '-' || // "-" is reserved by couchdb name.charAt(0) === '-' || // "-" is reserved by couchdb
name.match(/[\/@\s\+%:]/) || name.match(/[\/\s\+%:]/) ||
name !== encodeURIComponent(name) ||
name === 'node_modules' || name === 'node_modules' ||
name === '__proto__' || name === '__proto__' ||
name === 'package.json' || name === 'package.json' ||