Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Getting empty Roles object instead null

  • Loading branch information...
commit 071954b20d3ba4835535ed50d3060ab141a463ef 1 parent ace7c3f
@Bukarinov Bukarinov authored
View
4 library/GeometriaLab/Permissions/Assertion/Roles/AbstractRoles.php
@@ -98,6 +98,10 @@ protected function hasRoleForProperty($property, $role, $resource, $objectId)
*/
protected function getPermissionByResourceName($resourceName)
{
+ if ($this->resourceRoles === null) {
+ return null;
+ }
+
if ($this->resourceRolesMap === null) {
// @TODO Add feature getting Model from array by id
foreach ($this->resourceRoles as $index => $resourceRole) {
Please sign in to comment.
Something went wrong with that request. Please try again.