Browse Source

fix(lint): fix eslint errors

renovate/lint-staged-8.x
Jack Mallers 7 years ago
parent
commit
15eacc7f47
  1. 3
      .eslintrc
  2. 2
      app/lnd/subscribe/invoices.js
  3. 2
      app/lnd/subscribe/transactions.js
  4. 6
      app/reducers/invoice.js
  5. 4
      app/reducers/transaction.js

3
.eslintrc

@ -22,7 +22,8 @@
"camelcase": 0,
"react/require-default-props": 0,
"max-len": ["error", 150],
"import/no-extraneous-dependencies": 0
"import/no-extraneous-dependencies": 0,
"no-new": 0
},
"plugins": [
"flowtype",

2
app/lnd/subscribe/invoices.js

@ -1,3 +1,5 @@
/* eslint-disable */
export default function subscribeToInvoices(mainWindow, lnd) {
const call = lnd.subscribeInvoices({})

2
app/lnd/subscribe/transactions.js

@ -1,3 +1,5 @@
/* eslint-disable */
export default function subscribeToTransactions(mainWindow, lnd) {
const call = lnd.subscribeTransactions({})

6
app/reducers/invoice.js

@ -104,8 +104,8 @@ export const invoiceUpdate = (event, { invoice }) => (dispatch) => {
dispatch({ type: UPDATE_INVOICE, invoice })
// HTML 5 desktop notification for the invoice update
const notifTitle = `You've been Zapped`
const notifBody = `Congrats, someone just paid an invoice of yours`
const notifTitle = 'You\'ve been Zapped'
const notifBody = 'Congrats, someone just paid an invoice of yours'
showNotification(notifTitle, notifBody)
}
@ -133,7 +133,7 @@ const ACTION_HANDLERS = {
[INVOICE_FAILED]: state => ({ ...state, invoiceLoading: false, data: null }),
[UPDATE_INVOICE]: (state, action) => {
const updatedInvoices = state.invoices.map(invoice => {
const updatedInvoices = state.invoices.map((invoice) => {
if (invoice.r_hash.toString('hex') !== action.invoice.r_hash.toString('hex')) { return invoice }
return {

4
app/reducers/transaction.js

@ -72,8 +72,8 @@ export const newTransaction = (event, { transaction }) => (dispatch) => {
dispatch({ type: ADD_TRANSACTION, transaction })
// HTML 5 desktop notification for the new transaction
const notifTitle = transaction.amount > 0 ? `On-chain Transaction Received!` : `On-chain Transaction Sent!`
const notifBody = transaction.amount > 0 ? `Lucky you, you just received a new on-chain transaction. I'm jealous.` : `Hate to see 'em go but love to watch 'em leave. Your on-chain transaction successfully sent.`
const notifTitle = transaction.amount > 0 ? 'On-chain Transaction Received!' : 'On-chain Transaction Sent!'
const notifBody = transaction.amount > 0 ? 'Lucky you, you just received a new on-chain transaction. I\'m jealous.' : 'Hate to see \'em go but love to watch \'em leave. Your on-chain transaction successfully sent.' // eslint-disable-line
showNotification(notifTitle, notifBody)
}

Loading…
Cancel
Save