Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Commit 5866f08

Browse files
author
Alexandre Van de Sande
committed
milli should have two l's
1 parent bacb03c commit 5866f08

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

lib/utils/config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ var ETH_UNITS = [
4747
'picoether',
4848
'nanoether',
4949
'microether',
50-
'miliether',
50+
'milliether',
5151
'nano',
5252
'micro',
53-
'mili',
53+
'milli',
5454
'ether',
5555
'grand',
5656
'Mether',

lib/utils/utils.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ var unitMap = {
5151
'microether': '1000000000000',
5252
'micro': '1000000000000',
5353
'finney': '1000000000000000',
54-
'miliether': '1000000000000000',
55-
'mili': '1000000000000000',
54+
'milliether': '1000000000000000',
55+
'milli': '1000000000000000',
5656
'ether': '1000000000000000000',
5757
'kether': '1000000000000000000000',
5858
'grand': '1000000000000000000000',
@@ -252,7 +252,7 @@ var getValueOfUnit = function (unit) {
252252
* - mwei picoether babbage
253253
* - gwei nanoether shannon nano
254254
* - -- microether szabo micro
255-
* - -- miliether finney mili
255+
* - -- milliether finney milli
256256
* - ether -- --
257257
* - kether einstein grand
258258
* - mether
@@ -279,7 +279,7 @@ var fromWei = function(number, unit) {
279279
* - mwei picoether babbage
280280
* - gwei nanoether shannon nano
281281
* - -- microether szabo micro
282-
* - -- miliether finney mili
282+
* - -- milliether finney milli
283283
* - ether -- --
284284
* - kether einstein grand
285285
* - mether

test/utils.toWei.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ describe('lib/utils/utils', function () {
2323
assert.equal(utils.toWei(1, 'babbage'), utils.toWei(1, 'picoether'));
2424
assert.equal(utils.toWei(1, 'shannon'), utils.toWei(1, 'nanoether'));
2525
assert.equal(utils.toWei(1, 'szabo'), utils.toWei(1, 'microether'));
26-
assert.equal(utils.toWei(1, 'finney'), utils.toWei(1, 'miliether'));
27-
assert.equal(utils.toWei(1, 'mili'), utils.toWei(1, 'miliether'));
28-
assert.equal(utils.toWei(1, 'mili'), utils.toWei(1000, 'micro'));
26+
assert.equal(utils.toWei(1, 'finney'), utils.toWei(1, 'milliether'));
27+
assert.equal(utils.toWei(1, 'milli'), utils.toWei(1, 'milliether'));
28+
assert.equal(utils.toWei(1, 'milli'), utils.toWei(1000, 'micro'));
2929

3030
assert.throws(function () {utils.toWei(1, 'wei1');}, Error);
3131
});

0 commit comments

Comments
 (0)