From 183bc0758aae7a7937eb85e67b7026e2a32122b4 Mon Sep 17 00:00:00 2001 From: Kamil Madejski Date: Wed, 21 Mar 2018 20:17:46 +0100 Subject: [PATCH] EZP-28934: Incorrect variable in policy check context (#2283) * EZP-28934: Incorrect variable in policy check context * Remove unecessary context --- eZ/Publish/Core/Repository/LocationService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eZ/Publish/Core/Repository/LocationService.php b/eZ/Publish/Core/Repository/LocationService.php index 7274e307e67..c2ccf580818 100644 --- a/eZ/Publish/Core/Repository/LocationService.php +++ b/eZ/Publish/Core/Repository/LocationService.php @@ -350,7 +350,7 @@ public function createLocation(ContentInfo $contentInfo, LocationCreateStruct $l $content = $this->repository->getContentService()->loadContent($contentInfo->id); $parentLocation = $this->loadLocation($locationCreateStruct->parentLocationId); - if (!$this->repository->canUser('content', 'manage_locations', $content->contentInfo, $parentLocation)) { + if (!$this->repository->canUser('content', 'manage_locations', $content->contentInfo)) { throw new UnauthorizedException('content', 'manage_locations'); }