close ssr query

This commit is contained in:
archer
2023-06-26 15:05:34 +08:00
parent deb9be4160
commit 95066262b7
5 changed files with 12 additions and 32 deletions

View File

@@ -140,8 +140,10 @@ const Home = () => {
useEffect(() => {
(async () => {
const { data: git } = await axios.get('https://api.github.com/repos/c121914yu/FastGPT');
setStar(git.stargazers_count);
try {
const { data: git } = await axios.get('https://api.github.com/repos/c121914yu/FastGPT');
setStar(git.stargazers_count);
} catch (error) {}
})();
}, []);