diff options
| author | CoDEmanX <[email protected]> | 2016-04-07 11:22:14 +0200 |
|---|---|---|
| committer | CoDEmanX <[email protected]> | 2016-04-07 13:48:29 +0200 |
| commit | b81c8877ba8083c92d84d6296ca06775d143ffcf (patch) | |
| tree | 5c3e8a6bc76ddb064194f38bf22e125d61cb4d82 | |
| parent | 649843ade73b730911506b8ecc6bf64bad10238c (diff) | |
| download | faker-b81c8877ba8083c92d84d6296ca06775d143ffcf.tar.xz faker-b81c8877ba8083c92d84d6296ca06775d143ffcf.zip | |
Correct spelling
| -rw-r--r-- | lib/finance.js | 10 | ||||
| -rw-r--r-- | lib/index.js | 4 | ||||
| -rw-r--r-- | test/finance.unit.js | 10 |
3 files changed, 12 insertions, 12 deletions
diff --git a/lib/finance.js b/lib/finance.js index 1db94dcf..07eaa98b 100644 --- a/lib/finance.js +++ b/lib/finance.js @@ -41,15 +41,15 @@ var Finance = function (faker) { * @method faker.finance.mask * @param {number} length * @param {boolean} parens - * @param {boolean} elipsis + * @param {boolean} ellipsis */ - self.mask = function (length, parens, elipsis) { + self.mask = function (length, parens, ellipsis) { //set defaults length = (length == 0 || !length || typeof length == 'undefined') ? 4 : length; parens = (parens === null) ? true : parens; - elipsis = (elipsis === null) ? true : elipsis; + ellipsis = (ellipsis === null) ? true : ellipsis; //create a template for length var template = ''; @@ -58,8 +58,8 @@ var Finance = function (faker) { template = template + '#'; } - //prefix with elipsis - template = (elipsis) ? ['...', template].join('') : template; + //prefix with ellipsis + template = (ellipsis) ? ['...', template].join('') : template; template = (parens) ? ['(', template, ')'].join('') : template; diff --git a/lib/index.js b/lib/index.js index ed0a664b..49637ef8 100644 --- a/lib/index.js +++ b/lib/index.js @@ -101,7 +101,7 @@ function Faker (opts) { "separator": "" }; - // Create a Getter for all definitions.foo.bar propetries + // Create a Getter for all definitions.foo.bar properties Object.keys(_definitions).forEach(function(d){ if (typeof self.definitions[d] === "undefined") { self.definitions[d] = {}; @@ -117,7 +117,7 @@ function Faker (opts) { get: function () { if (typeof self.locales[self.locale][d] === "undefined" || typeof self.locales[self.locale][d][p] === "undefined") { // certain localization sets contain less data then others. - // in the case of a missing defintion, use the default localeFallback to substitute the missing set data + // in the case of a missing definition, use the default localeFallback to substitute the missing set data // throw new Error('unknown property ' + d + p) return self.locales[localeFallback][d][p]; } else { diff --git a/test/finance.unit.js b/test/finance.unit.js index 6bbb51c6..8be7d2c8 100644 --- a/test/finance.unit.js +++ b/test/finance.unit.js @@ -58,7 +58,7 @@ describe('finance.js', function () { }); - describe('mask( length, parens, elipsis )', function () { + describe('mask( length, parens, ellipsis )', function () { it("should set a default length", function () { var expected = 4; //default account mask length @@ -111,7 +111,7 @@ describe('finance.js', function () { }); - it("should by default include an elipsis", function () { + it("should by default include an ellipsis", function () { var expected = true; @@ -127,10 +127,10 @@ describe('finance.js', function () { it("should work when random variables are passed into the arguments", function () { var length = faker.random.number(20); - var elipsis = (length % 2 === 0) ? true : false; - var parens = !elipsis; + var ellipsis = (length % 2 === 0) ? true : false; + var parens = !ellipsis; - var mask = faker.finance.mask(length, elipsis, parens); + var mask = faker.finance.mask(length, ellipsis, parens); assert.ok(mask); }); |
