disallow toggleStar method for crawlers

This commit is contained in:
ghost 2023-11-04 11:04:05 +02:00
parent 178ab23031
commit d1e9e72401

View File

@ -318,6 +318,12 @@ class UserController extends AbstractController
);
}
// Block crawler requests
if (in_array($request->getClientIp(), explode('|', $this->getParameter('app.crawlers'))))
{
throw $this->createNotFoundException();
}
// Init target user
if (!$userTarget = $userService->getUser($request->get('userId')))
{