Skip to content

Commit 6f1f3e5

Browse files
committed
standard lint fixes
1 parent 1a31a4b commit 6f1f3e5

File tree

3 files changed

+40
-31
lines changed

3 files changed

+40
-31
lines changed

examples/rest2/wallets.js

+11-9
Original file line numberDiff line numberDiff line change
@@ -72,15 +72,17 @@ module.exports = runExample({
7272
prepareAmount(balance),
7373
prepareAmount(balanceAvailable),
7474

75-
...(_isFinite(value) ? [
76-
prepareAmount(value),
77-
currency !== valueCCY
78-
? prepareAmount(lastPrices[symbolForWallet({ currency })])
79-
: 1
80-
] : [
81-
'-',
82-
'-'
83-
])
75+
...(_isFinite(value)
76+
? [
77+
prepareAmount(value),
78+
currency !== valueCCY
79+
? prepareAmount(lastPrices[symbolForWallet({ currency })])
80+
: 1
81+
]
82+
: [
83+
'-',
84+
'-'
85+
])
8486
]
8587
})
8688

examples/util/run_example.js

+27-21
Original file line numberDiff line numberDiff line change
@@ -99,27 +99,33 @@ module.exports = (args = {}, example = () => { }) => {
9999
debug,
100100
debugTable,
101101

102-
...(!readline ? {} : {
103-
readline: Readline.createInterface({
104-
input: process.stdin,
105-
output: process.stdout,
106-
terminal: false
107-
})
108-
}),
109-
110-
...(!rest ? {} : {
111-
rest: new RESTv2({
112-
...(restEnv ? argsFromEnv('REST_URL') : {}),
113-
...restArgs
114-
})
115-
}),
116-
117-
...(!ws ? {} : {
118-
ws: new WSv2({
119-
...(wsEnv ? argsFromEnv('WS_URL') : {}),
120-
...wsArgs
121-
})
122-
})
102+
...(!readline
103+
? {}
104+
: {
105+
readline: Readline.createInterface({
106+
input: process.stdin,
107+
output: process.stdout,
108+
terminal: false
109+
})
110+
}),
111+
112+
...(!rest
113+
? {}
114+
: {
115+
rest: new RESTv2({
116+
...(restEnv ? argsFromEnv('REST_URL') : {}),
117+
...restArgs
118+
})
119+
}),
120+
121+
...(!ws
122+
? {}
123+
: {
124+
ws: new WSv2({
125+
...(wsEnv ? argsFromEnv('WS_URL') : {}),
126+
...wsArgs
127+
})
128+
})
123129
}
124130
} catch (e) {
125131
debug('error loading config: %s', e.message)

lib/transports/ws2.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,8 @@ class WSv2 extends EventEmitter {
473473
return authSeq !== this._lastAuthSeq
474474
? new Error(
475475
`invalid auth seq #, expected no advancement but got ${authSeq}`
476-
) : null
476+
)
477+
: null
477478
}
478479

479480
if (authSeq === this._lastAuthSeq) {

0 commit comments

Comments
 (0)