fix: restore quotes stripped by heredoc in market.ts

This commit is contained in:
Manohar 2026-05-15 04:17:22 +00:00
parent c53c188ae4
commit 2f13c0d7a2

View file

@ -55,11 +55,11 @@ async function fetchFromAngel(): Promise<MarketQuote[]> {
const tokenMap: Record<string, string[]> = {}; const tokenMap: Record<string, string[]> = {};
// We match by tradingSymbol because exchangeType is sometimes undefined in response // We match by tradingSymbol because exchangeType is sometimes undefined in response
const symToKey: Record<string, string> = { const symToKey: Record<string, string> = {
BSX: SENSEX, // BSE token 1 'BSX': 'SENSEX',
USDINR: USDINR, // CDS token 1 'USDINR': 'USDINR',
NIFTY: NIFTY50, 'NIFTY': 'NIFTY50',
BANKNIFTY: BANKNIFTY, 'BANKNIFTY': 'BANKNIFTY',
INDIA VIX: INDIAVIX, 'INDIA VIX': 'INDIAVIX',
}; };
for (const idx of INDEX_TOKENS) { for (const idx of INDEX_TOKENS) {
@ -68,8 +68,8 @@ async function fetchFromAngel(): Promise<MarketQuote[]> {
} }
const r = await axios.post( const r = await axios.post(
BASE + /rest/secure/angelbroking/market/v1/quote/, BASE + '/rest/secure/angelbroking/market/v1/quote/',
{ mode: FULL, exchangeTokens: tokenMap }, { mode: 'FULL', exchangeTokens: tokenMap },
{ headers, timeout: 8000 } { headers, timeout: 8000 }
); );