remove console logs
This commit is contained in:
parent
b974a84461
commit
9c8ef98cfd
|
@ -109,7 +109,6 @@ export const queryBars = async (
|
|||
|
||||
export default {
|
||||
onReady: (callback: (configuration: DatafeedConfiguration) => void) => {
|
||||
// console.log('[onReady]: Method call')
|
||||
setTimeout(() => callback(configurationData as any))
|
||||
},
|
||||
|
||||
|
@ -128,14 +127,6 @@ export default {
|
|||
// _onResolveErrorCallback: any,
|
||||
// _extension: any
|
||||
) => {
|
||||
// console.log(
|
||||
// '[resolveSymbol]: Method call',
|
||||
// symbolAddress,
|
||||
// onSymbolResolvedCallback
|
||||
// )
|
||||
// const symbols = await getAllSymbols()
|
||||
// let symbolItem = symbols.find((item: any) => item.address === symbolAddress)
|
||||
// console.log('========symbols:', symbolItem, symbols)
|
||||
let symbolItem:
|
||||
| {
|
||||
address: string
|
||||
|
@ -175,7 +166,6 @@ export default {
|
|||
format: 'price',
|
||||
}
|
||||
|
||||
// console.log('[resolveSymbol]: Symbol resolved', symbolAddress)
|
||||
onSymbolResolvedCallback(symbolInfo)
|
||||
},
|
||||
getBars: async (
|
||||
|
@ -215,7 +205,6 @@ export default {
|
|||
...bars[bars.length - 1],
|
||||
})
|
||||
}
|
||||
// console.log(`[getBars]: returned ${bars.length} bar(s)`)
|
||||
onHistoryCallback(bars, {
|
||||
noData: false,
|
||||
})
|
||||
|
@ -232,10 +221,6 @@ export default {
|
|||
subscriberUID: string,
|
||||
onResetCacheNeededCallback: () => void
|
||||
) => {
|
||||
// console.log(
|
||||
// '[subscribeBars]: Method call with subscriberUID:',
|
||||
// subscriberUID
|
||||
// )
|
||||
subscribeOnStream(
|
||||
symbolInfo,
|
||||
resolution,
|
||||
|
|
|
@ -21,7 +21,7 @@ socket.addEventListener('open', (_event) => {
|
|||
socket.addEventListener('message', (msg) => {
|
||||
const data = JSON.parse(msg.data)
|
||||
|
||||
if (data.type !== 'PRICE_DATA') return console.log(data)
|
||||
if (data.type !== 'PRICE_DATA') return console.warn(data)
|
||||
|
||||
const currTime = data.data.unixTime * 1000
|
||||
const lastBar = subscriptionItem.lastBar
|
||||
|
@ -39,7 +39,6 @@ socket.addEventListener('message', (msg) => {
|
|||
close: data.data.c,
|
||||
volume: data.data.v,
|
||||
}
|
||||
// console.log('[socket] Generate new bar')
|
||||
} else {
|
||||
bar = {
|
||||
...lastBar,
|
||||
|
@ -48,7 +47,6 @@ socket.addEventListener('message', (msg) => {
|
|||
close: data.data.c,
|
||||
volume: data.data.v,
|
||||
}
|
||||
// console.log('[socket] Update the latest bar by price')
|
||||
}
|
||||
|
||||
subscriptionItem.lastBar = bar
|
||||
|
|
|
@ -3,8 +3,6 @@ export const fetchChartData = async (
|
|||
quoteTokenId: string | undefined,
|
||||
daysToShow: string
|
||||
) => {
|
||||
console.log('fetching chart:', baseTokenId, quoteTokenId)
|
||||
|
||||
if (!baseTokenId || !quoteTokenId) return
|
||||
try {
|
||||
const [inputResponse, outputResponse] = await Promise.all([
|
||||
|
|
|
@ -21,7 +21,7 @@ const getRecentPerformance = async (
|
|||
|
||||
setTps(tps)
|
||||
} catch {
|
||||
console.log('Unable to fetch TPS')
|
||||
console.warn('Unable to fetch TPS')
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -33,8 +33,6 @@ const PerpMarketsTable = ({
|
|||
const showTableView = width ? width > breakpoints.md : false
|
||||
const rate = usePerpFundingRate()
|
||||
|
||||
console.log(coingeckoPrices.find((asset) => asset.symbol === 'soBTC'))
|
||||
|
||||
return (
|
||||
<ContentBox hideBorder hidePadding>
|
||||
{showTableView ? (
|
||||
|
|
|
@ -76,7 +76,7 @@ const TradingViewChartKline = ({ setIsFullView, isFullView }: Props) => {
|
|||
return dataList
|
||||
} catch (e) {
|
||||
setIsLoading(false)
|
||||
console.log(e)
|
||||
console.error(e)
|
||||
return []
|
||||
}
|
||||
}
|
||||
|
@ -132,7 +132,7 @@ const TradingViewChartKline = ({ setIsFullView, isFullView }: Props) => {
|
|||
try {
|
||||
fetchFreshData(365)
|
||||
} catch (e) {
|
||||
console.log('Error fetching new data')
|
||||
console.error('Error fetching new data')
|
||||
}
|
||||
chart.loadMore(() => null)
|
||||
})
|
||||
|
|
|
@ -99,10 +99,6 @@ const UnsettledTrades = ({
|
|||
mangoAccountPnl >= 0 ? mangoAccount : filteredAccounts[0].mangoAccount
|
||||
const unprofitableAccount =
|
||||
mangoAccountPnl < 0 ? mangoAccount : filteredAccounts[0].mangoAccount
|
||||
// const profitableAccount = mangoAccount
|
||||
// const unprofitableAccount =
|
||||
// filteredAccounts[filteredAccounts.length - 1].mangoAccount
|
||||
// console.log('unprofitableAccount', unprofitableAccount)
|
||||
|
||||
const txid = await client.perpSettlePnl(
|
||||
group,
|
||||
|
|
|
@ -1034,7 +1034,7 @@ const mangoStore = create<MangoStore>()(
|
|||
state.selectedMarket.fills = loadedFills
|
||||
})
|
||||
} catch (err) {
|
||||
console.log('Error fetching fills:', err)
|
||||
console.error('Error fetching fills:', err)
|
||||
}
|
||||
},
|
||||
async fetchTradeHistory(offset = 0) {
|
||||
|
@ -1087,8 +1087,6 @@ const mangoStore = create<MangoStore>()(
|
|||
)
|
||||
newProvider.opts.skipPreflight = true
|
||||
const newClient = initMangoClient(newProvider)
|
||||
console.log('here')
|
||||
|
||||
set((state) => {
|
||||
state.connection = newConnection
|
||||
state.client = newClient
|
||||
|
|
Loading…
Reference in New Issue