From 6c37e8f77400b03bfb4c4db3925f662538031625 Mon Sep 17 00:00:00 2001 From: Steve Boyd Date: Wed, 5 Jun 2024 16:57:21 +1200 Subject: [PATCH] ENH Use class name instead of self --- src/Forms/GridField/GridFieldAddByDBField.php | 2 +- src/Model/Blog.php | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Forms/GridField/GridFieldAddByDBField.php b/src/Forms/GridField/GridFieldAddByDBField.php index ff5509e..9561305 100644 --- a/src/Forms/GridField/GridFieldAddByDBField.php +++ b/src/Forms/GridField/GridFieldAddByDBField.php @@ -234,6 +234,6 @@ class GridFieldAddByDBField implements GridField_ActionProvider, GridField_HTMLP $forTemplate->Fields->push($textField); $forTemplate->Fields->push($addAction); - return [$this->targetFragment => $forTemplate->renderWith(self::class)]; + return [$this->targetFragment => $forTemplate->renderWith(GridFieldAddByDBField::class)]; } } diff --git a/src/Model/Blog.php b/src/Model/Blog.php index d3aeec9..c843997 100644 --- a/src/Model/Blog.php +++ b/src/Model/Blog.php @@ -475,7 +475,7 @@ class Blog extends Page implements PermissionProvider return $extended; } - return Permission::checkMember($member, self::MANAGE_USERS); + return Permission::checkMember($member, Blog::MANAGE_USERS); } /** @@ -499,7 +499,7 @@ class Blog extends Page implements PermissionProvider return true; } - return Permission::checkMember($member, self::MANAGE_USERS); + return Permission::checkMember($member, Blog::MANAGE_USERS); } /** @@ -523,7 +523,7 @@ class Blog extends Page implements PermissionProvider return true; } - return Permission::checkMember($member, self::MANAGE_USERS); + return Permission::checkMember($member, Blog::MANAGE_USERS); } /**