Skip to content

Commit

Permalink
has_fetch_OHLCV → has_fetch_ohlcv / fetchL2OrderBook → fetch_l2_order…
Browse files Browse the repository at this point in the history
…_book (automatic conversion)
  • Loading branch information
xpl committed Jan 17, 2018
1 parent 751c9ca commit 0b2fafe
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions js/base/Exchange.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@ module.exports = class Exchange {
this.userAgent = undefined
this.twofa = false // two-factor authentication (2FA)
this.timeframes = undefined

// TODO: generate
this.hasPublicAPI = true
this.hasPrivateAPI = true
this.hasCORS = false
Expand Down Expand Up @@ -156,8 +158,6 @@ module.exports = class Exchange {

this.arrayConcat = (a, b) => a.concat (b)

// TODO: generate

const names = Object.getOwnPropertyNames (this).concat (
Object.getOwnPropertyNames (this.constructor.prototype))

Expand Down
3 changes: 1 addition & 2 deletions js/base/functions/string.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ module.exports =
{ uuid: a => a ? (a ^ Math.random () * 16 >> a / 4).toString (16)
: ([1e7]+-1e3+-4e3+-8e3+-1e11).replace (/[018]/g, uuid)

, unCamelCase: s => s.replace (/[a-z][A-Z]/g, x => x[0] + '_' + x[1].toLowerCase ()) // hasFetchOHLCV → has_fetch_oHLCV
.replace (/[a-z][A-Z]/g, x => x[0].toUpperCase () + x[1]) // has_fetch_oHLCV → has_fetch_OHLCV
, unCamelCase: s => s.replace (/[a-z0-9][A-Z]/g, x => x[0] + '_' + x[1]).toLowerCase () // hasFetchOHLCV → has_fetch_ohlcv

, capitalize: s => s.length
? (s.charAt (0).toUpperCase () + s.slice (1))
Expand Down

0 comments on commit 0b2fafe

Please sign in to comment.