Skip to content

Commit

Permalink
Fix review comments
Browse files Browse the repository at this point in the history
Signed-off-by: Artem Savchenko <[email protected]>
  • Loading branch information
ArtyomSavchenko committed Dec 3, 2024
1 parent 445af9a commit b9a0a8e
Showing 1 changed file with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,11 @@
export let object: WithLookup<TestResult> | undefined
let isLoading = true
let hasNext = false
let navigateToNext = false
const client = getClient()
const hierarchy = client.getHierarchy()
testIteratorStore.subscribe(() => {
const unsubscribe = testIteratorStore.subscribe(() => {
hasNext = testResultIteratorProvider.getIterator()?.hasNext() ?? false
})
Expand All @@ -41,13 +40,11 @@
isLoading = false
})
onDestroy(() => {
if (navigateToNext) {
testResultIteratorProvider.reset()
}
testResultIteratorProvider.reset()
unsubscribe()
})
async function goToNextItem (): Promise<void> {
navigateToNext = true
const iterator = testResultIteratorProvider.getIterator()
if (iterator !== undefined) {
const nextItem = iterator.next()
Expand Down

0 comments on commit b9a0a8e

Please sign in to comment.