Skip to content

Commit c8445ea

Browse files
committed
Fix sentry errors
1 parent 98687d5 commit c8445ea

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

components/modules/block/UpcomingBlockCard.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,9 @@ onMounted(() => {
9898
if (rainEl.value) rainEl.value.appendChild(blockIcon)
9999
100100
setTimeout(() => {
101-
rainEl.value?.removeChild(blockIcon)
101+
if (rainEl.value && rainEl.value?.contains(blockIcon)) {
102+
rainEl.value.removeChild(blockIcon)
103+
}
102104
}, 5_000)
103105
}, 500)
104106
})

components/widgets/TransactionsWidget.vue

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@ const getHistogram = async (sectorOffset) => {
3232
period: "hour",
3333
from: parseInt(DateTime.now().minus({ hours: 24 - sectorOffset }).ts / 1_000),
3434
})
35-
histogram.value = data.reverse()
35+
36+
if (!data?.length) return
37+
38+
histogram.value = data?.reverse()
3639
}
3740
3841
const buildHistogram = async () => {
@@ -49,6 +52,8 @@ const buildHistogram = async () => {
4952
5053
await getHistogram(sectorOffset)
5154
55+
if (!histogram.value.length) return
56+
5257
const items = [...histogram.value]
5358
5459
let target = 0
@@ -138,7 +143,7 @@ const getSectorName = (item) => {
138143
</Flex>
139144
</Flex>
140145
141-
<Skeleton w="20" h="12" />
146+
<Skeleton v-if="isLoading" w="20" h="12" />
142147
</Flex>
143148
</Flex>
144149

0 commit comments

Comments
 (0)