Skip to content

Commit

Permalink
throws Exception when trying to add Recents phrase to database
Browse files Browse the repository at this point in the history
  • Loading branch information
cinadia committed May 28, 2024
1 parent c19919b commit badab68
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/src/main/java/com/willowtree/vocable/PhrasesUseCase.kt
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ class PhrasesUseCase(
localizedUtterance = localizedUtterance,
sortOrder = legacyPhrasesRepository.getPhrasesForCategory(parentCategoryId).size
))
} else {
throw Exception("The 'Recents' category is not a true category -" +
" it is a filter applied to true categories. Therefore, saving phrases from " +
"the Recents 'category' is not supported.")
}
}
}

0 comments on commit badab68

Please sign in to comment.