Browse Source

fix: null type error

GyDi 3 years ago
parent
commit
4f56c38599
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/pages/profile.tsx

+ 1 - 0
src/pages/profile.tsx

@@ -22,6 +22,7 @@ const ProfilePage = () => {
 
   useEffect(() => {
     if (profiles.current == null) return;
+    if (!profiles.items) profiles.items = [];
 
     const profile = profiles.items![profiles.current];
     if (!profile) return;