]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/middlewares/validators/follows.ts
Add ability to search video channels
[github/Chocobozzz/PeerTube.git] / server / middlewares / validators / follows.ts
index faefc1179a17e7a3321ed0c70c2d35c254c195fa..73fa28be95556bf83a7e7efc50716c6eba497e37 100644 (file)
@@ -38,7 +38,7 @@ const removeFollowingValidator = [
     if (areValidationErrors(req, res)) return
 
     const serverActor = await getServerActor()
-    const follow = await ActorFollowModel.loadByActorAndTargetNameAndHost(serverActor.id, SERVER_ACTOR_NAME, req.params.host)
+    const follow = await ActorFollowModel.loadByActorAndTargetNameAndHostForAPI(serverActor.id, SERVER_ACTOR_NAME, req.params.host)
 
     if (!follow) {
       return res