refactor: improve error handling and response structure for getThreads API function

This commit is contained in:
Thibault Pouch
2026-03-18 10:59:01 +01:00
parent e7d1cda356
commit bc9d93fe90
2 changed files with 17 additions and 5 deletions

View File

@@ -217,7 +217,7 @@ export default function ForumPage() {
{!loading && !error && (
filteredCategories.length === 0 ? (
<div className="crt-box" style={{ padding: '2rem', textAlign: 'center', color: 'var(--color-text-muted)', fontFamily: 'var(--font-mono)' }}>
No results found for "{search}"
{search.trim() ? `No results found for "${search}"` : 'No forum categories available yet.'}
</div>
) : (
filteredCategories.map((cat) => (