| @@ -12,9 +12,8 @@ | ||
| 12 | 12 | |
| 13 | 13 | use Parsely\Endpoints\Base_Endpoint; |
| 14 | 14 | use Parsely\Parsely; |
| 15 | 15 | use WP_Error; |
| 16 | -use WP_REST_Request; | |
| 17 | 16 | |
| 18 | 17 | /** |
| 19 | 18 | * Class for Analytics Posts API (`/analytics/posts`). |
| 20 | 19 | * |
| @@ -65,14 +64,12 @@ | ||
| 65 | 64 | * Returns whether the endpoint is available for access by the current |
| 66 | 65 | * user. |
| 67 | 66 | * |
| 68 | 67 | * @since 3.14.0 |
| 69 | - * @since 3.16.0 Added the `$request` parameter. | |
| 70 | 68 | * |
| 71 | - * @param WP_REST_Request|null $request The request object. | |
| 72 | 69 | * @return bool |
| 73 | 70 | */ |
| 74 | - public function is_available_to_current_user( $request = null ): bool { | |
| 71 | + public function is_available_to_current_user(): bool { | |
| 75 | 72 | return current_user_can( |
| 76 | 73 | // phpcs:ignore WordPress.WP.Capabilities.Undetermined |
| 77 | 74 | $this->apply_capability_filters( |
| 78 | 75 | Base_Endpoint::DEFAULT_ACCESS_CAPABILITY |