Procházet zdrojové kódy

chore(types): remove unnecessary type assertion (#12563)

webfansplz před 3 roky
rodič
revize
ff2d52f7ac
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2 2
      src/v3/apiWatch.ts

+ 2 - 2
src/v3/apiWatch.ts

@@ -221,7 +221,7 @@ function doWatch(
   } else if (isFunction(source)) {
     if (cb) {
       // getter with cb
-      getter = () => call(source as Function, WATCHER_GETTER)
+      getter = () => call(source, WATCHER_GETTER)
     } else {
       // no cb -> simple effect
       getter = () => {
@@ -231,7 +231,7 @@ function doWatch(
         if (cleanup) {
           cleanup()
         }
-        return call(source as Function, WATCHER, [onCleanup])
+        return call(source, WATCHER, [onCleanup])
       }
     }
   } else {