TradingView resolveSymbol method called twice

Viewed 120

I'm trying to integrate TradingView library with my web app. The chart is loading fine, but when loading both, resolveSymbol method is called twice.

Datafeed.Container.prototype.resolveSymbol = function (
    symbolName,
    onSymbolResolvedCallback,
    onResolveErrorCallback
  ) {
    this._send(
      datafeedUrl + this._symbolResolveURL,
      {
        symbol: symbolName ,
      },
      function (dataObj) {
          onSymbolResolvedCallback(dataObj);
      }
    );
  };

Actually the data returned on both times are the same. The Chrome dev tools network tab shows the calls as below

enter image description here

What is that going wrong? Somehow the library assumes the symbol is not resolved. How to rectify that?

0 Answers
Related