Skip to content

Commit

Permalink
fix(bybit): remove isUnifiedMarginEnabled from ws
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosmiei committed Mar 1, 2023
1 parent 0f08e13 commit 83f895b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions js/pro/bybit.js
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,8 @@ module.exports = class bybit extends bybitRest {
symbol = this.symbol (symbol);
messageHash += ':' + symbol;
}
const isUnifiedMargin = await this.isUnifiedMarginEnabled ();
const unified = await this.isUnifiedEnabled ();
const isUnifiedMargin = this.safeValue (unified, 0, false);
const url = this.getUrlByMarketType (symbol, true, isUnifiedMargin, method, params);
await this.authenticate (url);
const topicByMarket = {
Expand Down Expand Up @@ -899,7 +900,8 @@ module.exports = class bybit extends bybitRest {
symbol = this.symbol (symbol);
messageHash += ':' + symbol;
}
const isUnifiedMargin = await this.isUnifiedMarginEnabled ();
const unified = await this.isUnifiedEnabled ();
const isUnifiedMargin = this.safeValue (unified, 0, false);
const url = this.getUrlByMarketType (undefined, true, isUnifiedMargin, method, params);
await this.authenticate (url);
const topicsByMarket = {
Expand Down Expand Up @@ -1164,7 +1166,8 @@ module.exports = class bybit extends bybitRest {
*/
const method = 'watchBalance';
const messageHash = 'balances';
const isUnifiedMargin = await this.isUnifiedMarginEnabled ();
const unified = await this.isUnifiedEnabled ();
const isUnifiedMargin = this.safeValue (unified, 0, false);
const url = this.getUrlByMarketType (undefined, true, isUnifiedMargin, method, params);
await this.authenticate (url);
const topicByMarket = {
Expand Down

0 comments on commit 83f895b

Please sign in to comment.