Explorar o código

Update SearchController

Daniel Supernault %!s(int64=6) %!d(string=hai) anos
pai
achega
8c88c88fc0
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      app/Http/Controllers/SearchController.php

+ 1 - 1
app/Http/Controllers/SearchController.php

@@ -36,7 +36,7 @@ class SearchController extends Controller
         $hash = hash('sha256', $tag);
         $tokens = Cache::remember('api:search:tag:'.$hash, now()->addMinutes(5), function () use ($tag) {
             $tokens = [];
-            if(Helpers::validateUrl($tag) != false && config('pixelfed.activitypub_enabled') == true) {
+            if(Helpers::validateUrl($tag) != false && config('pixelfed.activitypub_enabled') == true && config('pixelfed.remote_follow_enabled') == true) {
                 $remote = Helpers::fetchFromUrl($tag);
                 if(isset($remote['type']) && in_array($remote['type'], ['Create', 'Person']) == true) {
                     $type = $remote['type'];