Skip to content

Commit

Permalink
fixed global leak in listTerms
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisumbel committed Mar 6, 2013
1 parent fa53db6 commit 79fbf5f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/natural/tfidf/tfidf.js
Expand Up @@ -98,7 +98,7 @@ TfIdf.prototype.tfidf = function(terms, d) {
TfIdf.prototype.listTerms = function(d) { TfIdf.prototype.listTerms = function(d) {
var terms = []; var terms = [];


for(term in this.documents[d]) { for(var term in this.documents[d]) {
terms.push({term: term, tfidf: this.tfidf(term, d)}) terms.push({term: term, tfidf: this.tfidf(term, d)})
} }


Expand Down

0 comments on commit 79fbf5f

Please sign in to comment.