Răsfoiți Sursa

chore: remove useless else (#245)

fisker Cheung 6 ani în urmă
părinte
comite
971cebc61c
1 a modificat fișierele cu 5 adăugiri și 5 ștergeri
  1. 5 5
      packages/runtime-core/src/suspense.ts

+ 5 - 5
packages/runtime-core/src/suspense.ts

@@ -68,10 +68,10 @@ export function normalizeSuspenseChildren(
       content: normalizeVNode(isFunction(d) ? d() : d),
       fallback: normalizeVNode(isFunction(fallback) ? fallback() : fallback)
     }
-  } else {
-    return {
-      content: normalizeVNode(children as VNodeChild),
-      fallback: normalizeVNode(null)
-    }
+  }
+
+  return {
+    content: normalizeVNode(children as VNodeChild),
+    fallback: normalizeVNode(null)
   }
 }