Skip to content

Commit

Permalink
fix(lint): fix small lint violations
Browse files Browse the repository at this point in the history
  • Loading branch information
schnogz committed Nov 27, 2021
1 parent b21f930 commit fec859f
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Map } from 'immutable-ext'
import { forEach, head, isEmpty, isNil, path, pathOr, prop, toLower } from 'ramda'
import { forEach, head, isEmpty, isNil, pathOr, prop, toLower } from 'ramda'
import { set } from 'ramda-lens'
import { call, put, select } from 'redux-saga/effects'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { length } from 'ramda'
import { select } from 'redux-saga/effects'

import * as S from '../../selectors'

// TODO: Better way to test that ?
export const isValidIndex = function* (index) {
const accounts = yield select(S.kvStore.eth.getAccounts)
return index >= 0 && index <= length(accounts.getOrElse([]))
Expand Down
2 changes: 2 additions & 0 deletions packages/blockchain-wallet-v4/src/transactions/bch.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,14 @@ export const _transformTx = (wallet, accountList, txNotes, tx) => {
const inputTagger = compose(tagCoin(wallet, accountList), unpackInput)
const outputTagger = tagCoin(wallet, accountList)
const [oData, outs] = mapAccum(appender(outputTagger), init, prop('out', tx))
// eslint-disable-next-line prefer-const
let [inputData, inputs] = ifElse(
compose(isCoinBase, prop('inputs')),
always([CoinBaseData(oData.total), [CoinbaseCoin(oData.total)]]),
(t) => mapAccum(appender(inputTagger), init, prop('inputs', t))
)(tx)

// eslint-disable-next-line prefer-const
let [outputData, outputs] = findLegacyChanges(inputs, inputData, outs, oData)

if (any(isDust, inputs) && any(isDust, outputs)) {
Expand Down
2 changes: 1 addition & 1 deletion packages/blockchain-wallet-v4/src/transactions/eth.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import moment from 'moment'
import { any, curry, equals, filter, head, includes, lift, map, path, prop, toLower } from 'ramda'
import { any, curry, equals, filter, head, includes, lift, map, prop, toLower } from 'ramda'

import { EthRawTxType } from '@core/network/api/eth/types'
import { calculateFee } from '@core/utils/eth'
Expand Down
2 changes: 1 addition & 1 deletion packages/blockchain-wallet-v4/src/types/Address.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ export const fromString = (keyOrAddr, createdTime, label, bipPass, { api, networ
key.compressed = false
const uad = utils.btc.keyPairToAddress(key)
return wrapPromiseInTask(() => api.getBalances([cad, uad])).fold(
(e) => {
() => {
key.compressed = true
return importAddress(key, createdTime, label, network)
},
Expand Down

0 comments on commit fec859f

Please sign in to comment.