We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 995abb7 commit 33c3861Copy full SHA for 33c3861
client/components/Encouragements/BlueCardsTestEncouragement.js
@@ -24,11 +24,12 @@ const BlueCardsTestEncouragement = ({ setShow }) => {
24
useEffect(() => {
25
if (!storyBlueCards) {
26
dispatch(getStoriesBlueFlashcards(learningLanguage, dictionaryLanguage))
27
+ return
28
}
- if (storyBlueCards?.length > 0) {
29
+ if (storyBlueCards.length > 0) {
30
setPrevBlueCards(storyBlueCards[0])
31
} else {
- setPrevBlueCards(null)
32
+ history.push('/home')
33
34
}, [storyBlueCards])
35
0 commit comments