Details
-
Bug
-
Resolution: Fixed
-
Medium
-
5.0.0rc1
-
None
-
Redhat rhel 6.2
mysql
Description
Hi
Seems like we are now unable to lookup urlaliases
I have a object ("/News")
And a function to look up urlaliases:
public function getLocationByPath( $path ) { if( isset( $path[0] ) && $path[0] != '/' ) { print " warning Prefixed $path with a forward slash --> /$path\n"; $path = "/$path"; } $urlAliasService = $this->repo->getURLAliasService(); $locationService = $this->repo->getLocationService(); $alias = $urlAliasService->lookup( $path, $this->lang ); return $locationService->loadLocation( $alias->destination->id ); // This is ezpublishapitesthelper.php:533 }
Then calling this function using getLocationByPath( '/News' ) causes the following backtrace:
1) eZPublishAPIInteger::testTC1397CreateIntegerObject eZ\Publish\Core\Base\Exceptions\InvalidArgumentValue: Argument 'locationId' is invalid: 'NULL' is wrong value /var/www/apache2php53/ezpublish5/vendor/ezsystems/ezpublish/eZ/Publish/Core/Repository/LocationService.php:195 /var/www/apache2php53/ezpublish5/vendor/ezsystems/ezpublish/eZ/Publish/Core/SignalSlot/LocationService.php:101 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/ezpublishapitests/classes/ezpublishapitesthelper.php:533 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/ezpublishapitests/tests/ezpublishapi/ezpublishapi/datatypes/integer/ezpublishapiinteger.php:156 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/selenium/classes/ezpselenesetest.php:698 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/ezpublishapitests/classes/ezpublishapitest.php:115 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/ezpublishapitests/tests/ezpublishapi/ezpublishapi/datatypes/integer/ezpublishapiinteger.php:137 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/extension/selenium/classes/ezpselenesetest.php:727 /var/www/apache2php53/ezpublish5/ezpublish_testsystem/tests/toolkit/ezptestrunner.php:372