Forráskód Böngészése

Update ApiV1Controller, fix follow/unfollow endpoints

Daniel Supernault 5 éve
szülő
commit
fb91892ee2
1 módosított fájl, 2 hozzáadás és 2 törlés
  1. 2 2
      app/Http/Controllers/Api/ApiV1Controller.php

+ 2 - 2
app/Http/Controllers/Api/ApiV1Controller.php

@@ -369,7 +369,7 @@ class ApiV1Controller extends Controller
 
 
         $target = Profile::where('id', '!=', $user->id)
         $target = Profile::where('id', '!=', $user->id)
             ->whereNull('status')
             ->whereNull('status')
-            ->findOrFail($item);
+            ->findOrFail($id);
 
 
         $private = (bool) $target->is_private;
         $private = (bool) $target->is_private;
         $remote = (bool) $target->domain;
         $remote = (bool) $target->domain;
@@ -454,7 +454,7 @@ class ApiV1Controller extends Controller
 
 
         $target = Profile::where('id', '!=', $user->id)
         $target = Profile::where('id', '!=', $user->id)
             ->whereNull('status')
             ->whereNull('status')
-            ->findOrFail($item);
+            ->findOrFail($id);
 
 
         $private = (bool) $target->is_private;
         $private = (bool) $target->is_private;
         $remote = (bool) $target->domain;
         $remote = (bool) $target->domain;