Comparing version 0.1.4 to 0.1.5
28
index.js
@@ -16,15 +16,19 @@ var async = require("async"); | ||
wordnet.validForms(input, function(results) { | ||
if (results && results.length !== 0) { | ||
for (i = 0; i < results.length; i++ ) { | ||
_ref = results[i].split('#'); | ||
word = _ref[0]; | ||
wordforms.push(word); | ||
if (/^[a-z]/i.test(input)) { | ||
wordnet.validForms(input, function(results) { | ||
if (results && results.length !== 0) { | ||
for (i = 0; i < results.length; i++ ) { | ||
_ref = results[i].split('#'); | ||
word = _ref[0]; | ||
wordforms.push(word); | ||
} | ||
next(null, reducer(_.uniq(wordforms))); | ||
} else { | ||
next(null, [input]); | ||
} | ||
next(null, reducer(_.uniq(wordforms))); | ||
} else { | ||
next(null, [input]); | ||
} | ||
}); | ||
}); | ||
} else { | ||
next(null, [input]); | ||
} | ||
}; | ||
@@ -31,0 +35,0 @@ |
{ | ||
"name": "lemmer", | ||
"version": "0.1.4", | ||
"version": "0.1.5", | ||
"description": "Wordnet Lemmer", | ||
@@ -10,8 +10,3 @@ "main": "index.js", | ||
"author": "Rob Ellis", | ||
"licenses": [ | ||
{ | ||
"type": "MIT", | ||
"url": "https://raw.github.com/silentrob/lemmer/master/LICENSE" | ||
} | ||
], | ||
"license": "MIT", | ||
"dependencies": { | ||
@@ -24,2 +19,9 @@ "WNdb": "3.1.1", | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/silentrob/lemmer.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/silentrob/lemmer/issues" | ||
}, | ||
"devDependencies": { | ||
@@ -26,0 +28,0 @@ "mocha": "2.2.3", |
@@ -24,2 +24,9 @@ var mocha = require("mocha"); | ||
it("undef", function(done) { | ||
Lem.lemmatize('__something__', function(err, res) { | ||
console.log(err, res); | ||
done(); | ||
}); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
4400
66
1
0