Skip to content

Commit f6119d2

Browse files
f3rnoJacobPlaster
authored andcommitted
(fix) RESTv2 [cb] -> cb find/replace error revert
1 parent 67b4d29 commit f6119d2

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

CHANGELOG

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# 3.0.9
2+
- RESTv2: fix [cb] find/replace error to cb where appropriate
3+
14
# 3.0.8
25
- RESTv2: fixes cancelOrderWithCid function
36
- RESTv2: removes cancelOrderWithDate function

lib/rest2.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ class RESTv2 {
299299
*/
300300
_cb (err, res, cb) {
301301
return new Promise((resolve, reject) => {
302-
const _isCbFunc = [cb] && _isFunction(cb)
302+
const _isCbFunc = _isFunction(cb)
303303
if (err) {
304304
if (err.error && err.error[1] === 10114) {
305305
err.message += ' see https://github.com/bitfinexcom/bitfinex-api-node/blob/master/README.md#nonce-too-small for help'
@@ -508,7 +508,7 @@ class RESTv2 {
508508
* @param {Function} [cb] - callback
509509
* @returns {Promise} p
510510
*/
511-
conf (keys = [], [cb] = () => {}) {
511+
conf (keys = [], cb = () => {}) {
512512
if (_isEmpty(keys)) {
513513
return Promise.resolve([])
514514
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "bfx-api-node-rest",
3-
"version": "3.0.8",
3+
"version": "3.0.9",
44
"description": "Official Bitfinex REST v1 & v2 API interfaces",
55
"engines": {
66
"node": ">=8.3.0"

0 commit comments

Comments
 (0)