Handle errors when loading feed
cgen-2386ef41d85242c4948f22f5f54f1aa8
This commit is contained in:
parent
13bd717336
commit
f27be067c3
1 changed files with 3 additions and 0 deletions
|
|
@ -91,6 +91,9 @@ export default function Feed() {
|
||||||
});
|
});
|
||||||
|
|
||||||
setItems(mapped);
|
setItems(mapped);
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Failed to load feed", error);
|
||||||
|
setItems([]);
|
||||||
} finally {
|
} finally {
|
||||||
setIsLoading(false);
|
setIsLoading(false);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue