Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2014-05-13 20:47:11 +0400
committerisaacs <i@izs.me>2014-05-13 20:47:34 +0400
commitb5c9b1a98740af158ccbb5a9598954d289c3ead6 (patch)
tree7954eac49f8f1e91a4c42c042cc02294c012de05 /node_modules/npm-user-validate
parent8965747a4fab1e1ac50c04f2f672feff479411f2 (diff)
npm-user-validate@0.1.0
Diffstat (limited to 'node_modules/npm-user-validate')
-rw-r--r--node_modules/npm-user-validate/README.md6
-rw-r--r--node_modules/npm-user-validate/npm-user-validate.js8
-rw-r--r--node_modules/npm-user-validate/package.json18
-rw-r--r--node_modules/npm-user-validate/test/pw.test.js10
4 files changed, 17 insertions, 25 deletions
diff --git a/node_modules/npm-user-validate/README.md b/node_modules/npm-user-validate/README.md
index 5e34f0aa0..53bdae5af 100644
--- a/node_modules/npm-user-validate/README.md
+++ b/node_modules/npm-user-validate/README.md
@@ -1,6 +1,6 @@
-[![Build Status](https://travis-ci.org/robertkowalski/npm-user-validate.png?branch=master)](https://travis-ci.org/robertkowalski/npm-user-validate)
-[![devDependency Status](https://david-dm.org/robertkowalski/npm-user-validate/dev-status.png)](https://david-dm.org/robertkowalski/npm-user-validate#info=devDependencies)
+[![Build Status](https://travis-ci.org/npm/npm-user-validate.png?branch=master)](https://travis-ci.org/npm/npm-user-validate)
+[![devDependency Status](https://david-dm.org/npm/npm-user-validate/dev-status.png)](https://david-dm.org/npm/npm-user-validate#info=devDependencies)
# npm-user-validate
-Validation for the npm client and npm-www (and probably other npm projects) \ No newline at end of file
+Validation for the npm client and npm-www (and probably other npm projects)
diff --git a/node_modules/npm-user-validate/npm-user-validate.js b/node_modules/npm-user-validate/npm-user-validate.js
index 853456f52..f18e13ccf 100644
--- a/node_modules/npm-user-validate/npm-user-validate.js
+++ b/node_modules/npm-user-validate/npm-user-validate.js
@@ -8,9 +8,7 @@ var requirements = exports.requirements = {
urlSafe: 'Username may not contain non-url-safe chars',
dot: 'Username may not start with "."'
},
- password: {
- badchars: 'Password passwords cannot contain these characters: \'!:@"'
- },
+ password: {},
email: {
valid: 'Email must be an email address'
}
@@ -41,9 +39,5 @@ function email (em) {
}
function pw (pw) {
- if (pw.match(/['!:@"]/)) {
- return new Error(requirements.password.badchars)
- }
-
return null
}
diff --git a/node_modules/npm-user-validate/package.json b/node_modules/npm-user-validate/package.json
index a05b95ef1..b9377c771 100644
--- a/node_modules/npm-user-validate/package.json
+++ b/node_modules/npm-user-validate/package.json
@@ -1,6 +1,6 @@
{
"name": "npm-user-validate",
- "version": "0.0.3",
+ "version": "0.1.0",
"description": "User validations for npm",
"main": "npm-user-validate.js",
"devDependencies": {
@@ -11,7 +11,7 @@
},
"repository": {
"type": "git",
- "url": "https://github.com/robertkowalski/npm-user-validate"
+ "url": "git://github.com/npm/npm-registry-mock.git"
},
"keywords": [
"npm",
@@ -23,15 +23,13 @@
"email": "rok@kowalski.gd"
},
"license": "BSD",
- "readme": "[![Build Status](https://travis-ci.org/robertkowalski/npm-user-validate.png?branch=master)](https://travis-ci.org/robertkowalski/npm-user-validate)\n[![devDependency Status](https://david-dm.org/robertkowalski/npm-user-validate/dev-status.png)](https://david-dm.org/robertkowalski/npm-user-validate#info=devDependencies)\n\n# npm-user-validate\n\nValidation for the npm client and npm-www (and probably other npm projects)",
+ "readme": "[![Build Status](https://travis-ci.org/npm/npm-user-validate.png?branch=master)](https://travis-ci.org/npm/npm-user-validate)\n[![devDependency Status](https://david-dm.org/npm/npm-user-validate/dev-status.png)](https://david-dm.org/npm/npm-user-validate#info=devDependencies)\n\n# npm-user-validate\n\nValidation for the npm client and npm-www (and probably other npm projects)\n",
"readmeFilename": "README.md",
"bugs": {
- "url": "https://github.com/robertkowalski/npm-user-validate/issues"
+ "url": "https://github.com/npm/npm-registry-mock/issues"
},
- "_id": "npm-user-validate@0.0.3",
- "dist": {
- "shasum": "7b147d11038083fb0ba2d60ff851dc20322aa9f6"
- },
- "_from": "npm-user-validate@0.0.3",
- "_resolved": "https://registry.npmjs.org/npm-user-validate/-/npm-user-validate-0.0.3.tgz"
+ "homepage": "https://github.com/npm/npm-registry-mock",
+ "_id": "npm-user-validate@0.1.0",
+ "_shasum": "358a5b5148ed3f79771d980388c6e34c4a61f638",
+ "_from": "npm-user-validate@latest"
}
diff --git a/node_modules/npm-user-validate/test/pw.test.js b/node_modules/npm-user-validate/test/pw.test.js
index e99c991cb..d57401da0 100644
--- a/node_modules/npm-user-validate/test/pw.test.js
+++ b/node_modules/npm-user-validate/test/pw.test.js
@@ -3,25 +3,25 @@ var v = require('../npm-user-validate.js').pw
test('pw contains a \'', function (t) {
err = v('\'')
- t.type(err, 'object')
+ t.type(err, 'null')
t.end()
})
test('pw contains a :', function (t) {
err = v(':')
- t.type(err, 'object')
+ t.type(err, 'null')
t.end()
})
test('pw contains a @', function (t) {
err = v('@')
- t.type(err, 'object')
+ t.notOk(err, 'null')
t.end()
})
test('pw contains a "', function (t) {
err = v('"')
- t.type(err, 'object')
+ t.type(err, 'null')
t.end()
})
@@ -29,4 +29,4 @@ test('pw is ok', function (t) {
err = v('duck')
t.type(err, 'null')
t.end()
-}) \ No newline at end of file
+})