diff --git a/eZ/Publish/Core/MVC/Symfony/View/Builder/ContentViewBuilder.php b/eZ/Publish/Core/MVC/Symfony/View/Builder/ContentViewBuilder.php
index <HASH>..<HASH> 100644
--- a/eZ/Publish/Core/MVC/Symfony/View/Builder/ContentViewBuilder.php
+++ b/eZ/Publish/Core/MVC/Symfony/View/Builder/ContentViewBuilder.php
@@ -130,7 +130,7 @@ class ContentViewBuilder implements ViewBuilder
                 throw new InvalidArgumentException('Location', 'Provided location does not belong to selected content');
             }
 
-            if (isset($parameters['contentId']) && $location->contentId !== $parameters['contentId']) {
+            if (isset($parameters['contentId']) && $location->contentId !== (int)$parameters['contentId']) {
                 throw new InvalidArgumentException(
                     'Location',
                     'Provided location does not belong to selected content as requested via contentId parameter'
EZP-<I>: Content View breaks when providing location id as param (#<I>)

* EZP-<I>: Content View breaks when providing location id as param



* Cast to int