FormsBulkActionEndpoint.php
2 months ago
FormsEndpoint.php
2 months ago
FormsListingEndpoint.php
1 month ago
index.php
2 months ago
FormsEndpoint.php
17 lines
| 1 | <?php declare(strict_types = 1); |
| 2 | |
| 3 | namespace MailPoet\Form\RestApi\Endpoints; |
| 4 | |
| 5 | if (!defined('ABSPATH')) exit; |
| 6 | |
| 7 | |
| 8 | use MailPoet\API\REST\Endpoint; |
| 9 | use MailPoet\Config\AccessControl; |
| 10 | use MailPoet\WP\Functions as WPFunctions; |
| 11 | |
| 12 | abstract class FormsEndpoint extends Endpoint { |
| 13 | public function checkPermissions(): bool { |
| 14 | return WPFunctions::get()->currentUserCan(AccessControl::PERMISSION_MANAGE_FORMS); |
| 15 | } |
| 16 | } |
| 17 |