mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
API Changes for Authenticator refactor
This commit is contained in:
parent
3f112ecfcd
commit
03125b8c6c
@ -21,6 +21,7 @@ use SilverStripe\Forms\GridField\GridFieldDataColumns;
|
||||
use SilverStripe\Forms\GridField\GridFieldPaginator;
|
||||
use SilverStripe\Forms\GridField\GridField;
|
||||
use SilverStripe\Core\Convert;
|
||||
use SilverStripe\Security\Security;
|
||||
use SilverStripe\View\ViewableData;
|
||||
use ReflectionClass;
|
||||
use SilverStripe\ORM\CMSPreviewable ;
|
||||
@ -399,7 +400,7 @@ class Report extends ViewableData
|
||||
public function canView($member = null)
|
||||
{
|
||||
if (!$member && $member !== false) {
|
||||
$member = Member::currentUser();
|
||||
$member = Security::getCurrentUser();
|
||||
}
|
||||
|
||||
$extended = $this->extendedCan('canView', $member);
|
||||
|
@ -17,6 +17,7 @@ use SilverStripe\ORM\ArrayList;
|
||||
use SilverStripe\ORM\SS_List;
|
||||
use SilverStripe\Security\Member;
|
||||
use SilverStripe\Security\PermissionProvider;
|
||||
use SilverStripe\Security\Security;
|
||||
use SilverStripe\View\ArrayData;
|
||||
use SilverStripe\View\Requirements;
|
||||
|
||||
@ -80,7 +81,7 @@ class ReportAdmin extends LeftAndMain implements PermissionProvider
|
||||
public function canView($member = null)
|
||||
{
|
||||
if (!$member && $member !== false) {
|
||||
$member = Member::currentUser();
|
||||
$member = Security::getCurrentUser();
|
||||
}
|
||||
|
||||
if (!parent::canView($member)) {
|
||||
|
Loading…
Reference in New Issue
Block a user