Skip to content
This repository has been archived by the owner on Oct 8, 2019. It is now read-only.

Commit

Permalink
Merge e5d3c6c into 1fed719
Browse files Browse the repository at this point in the history
  • Loading branch information
jtormey committed Dec 17, 2015
2 parents 1fed719 + e5d3c6c commit 5877916
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion app/partials/login.jade
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ div
span(translate="CLICK_HERE_TO_CREATE_WALLET")
p.em-300(translate="LOGIN_BELOW")
//GUID & Password fields
form.ptl.form-horizontal.clearfix(role="form")
form.ptl.form-horizontal.clearfix(role="form" autocomplete="off" novalidate)
.form-group(ng-class="{'has-error': errors.uid}")
label.em-500(translate="UID", for="UID_input")
div
Expand Down
2 changes: 1 addition & 1 deletion assets/js/services/currency.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ function currency($q, MyBlockchainApi) {

function decimalPlacesForCurrency(currency) {
if (currency == null) return null;
let decimalPlaces = ({ 'BTC': 8, 'mBTC': 6, 'bits': 4 })[currency.code];
let decimalPlaces = ({ 'BTC': 8, 'mBTC': 5, 'bits': 2 })[currency.code];
return decimalPlaces || 2;
}

Expand Down
6 changes: 3 additions & 3 deletions tests/services/currency.service.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,12 @@ describe('currency', () => {

it('should give "mBTC" the right places', inject((currency) => {
let decimals = currency.decimalPlacesForCurrency(currency.bitCurrencies[1]);
expect(decimals).toEqual(6);
expect(decimals).toEqual(5);
}));

it('should give "bits" the right places', inject((currency) => {
let decimals = currency.decimalPlacesForCurrency(currency.bitCurrencies[2]);
expect(decimals).toEqual(4);
expect(decimals).toEqual(2);
}));

it('should give fiat the right places', inject((currency) => {
Expand Down Expand Up @@ -153,7 +153,7 @@ describe('currency', () => {

describe('formatCurrencyForView()', () => {
let amount = 0.123456789;
let viewValues = ['0.12345679 BTC', '0.123457 mBTC', '0.1235 bits'];
let viewValues = ['0.12345679 BTC', '0.12346 mBTC', '0.12 bits'];

for (let i in viewValues) {
it(`should format btc currency ${i}`, inject((Wallet, currency) => {
Expand Down

0 comments on commit 5877916

Please sign in to comment.