1
0
Fork 0
mirror of https://github.com/seejohnrun/haste-server.git synced 2024-11-22 04:31:21 +00:00

Removed unused lines

This commit is contained in:
Klas af Geijerstam 2017-06-26 18:09:13 +02:00 committed by GitHub
parent 80f0618736
commit d66bc9a6c4

View file

@ -1,5 +1,4 @@
var fs = require('fs') var fs = require('fs')
var dictionary;
var DictionaryGenerator = function(options) { var DictionaryGenerator = function(options) {
//Options //Options
@ -18,10 +17,8 @@ var DictionaryGenerator = function(options) {
//Generates a dictionary-based key, of keyLength words //Generates a dictionary-based key, of keyLength words
DictionaryGenerator.prototype.createKey = function(keyLength) { DictionaryGenerator.prototype.createKey = function(keyLength) {
var text = ''; var text = '';
for(var i = 0; i < keyLength; i++) { for(var i = 0; i < keyLength; i++)
var index =Math.floor(Math.random()*this.dictionary.length); text += this.dictionary[Math.floor(Math.random()*this.dictionary.length)];
text += this.dictionary[index];
}
return text; return text;
}; };