summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwebchick2013-08-29 16:38:22 (GMT)
committerwebchick2013-08-29 16:38:22 (GMT)
commitdfda80318a559345eacc9e2f752b41419f207a00 (patch)
tree942aeef21f5c69d861696118273d54c38f0b3304
parent7a88ed3bb9c859b5f23a80734f6581890c51a322 (diff)
Issue #2062015 by InternetDevels, phiit: Replace user_access() calls with ->hasPermission() in picture module.
-rw-r--r--core/modules/picture/lib/Drupal/picture/PictureMappingAccessController.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/modules/picture/lib/Drupal/picture/PictureMappingAccessController.php b/core/modules/picture/lib/Drupal/picture/PictureMappingAccessController.php
index 2696100..281bcee 100644
--- a/core/modules/picture/lib/Drupal/picture/PictureMappingAccessController.php
+++ b/core/modules/picture/lib/Drupal/picture/PictureMappingAccessController.php
@@ -24,7 +24,7 @@ class PictureMappingAccessController extends EntityAccessController {
return TRUE;
}
elseif (in_array($operation, array('update', 'delete'))) {
- return user_access('administer pictures', $account);
+ return $account->hasPermission('administer pictures');
}
}
@@ -32,7 +32,7 @@ class PictureMappingAccessController extends EntityAccessController {
* {@inheritdoc}
*/
protected function checkCreateAccess(AccountInterface $account, array $context, $entity_bundle = NULL) {
- return user_access('administer pictures', $account);
+ return $account->hasPermission('administer pictures');
}
}