| @@ -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 | use function Parsely\Utils\convert_to_associative_array; |
| 19 | 18 | |
| 20 | 19 | /** |
| @@ -33,14 +32,12 @@ | ||
| 33 | 32 | * Returns whether the endpoint is available for access by the current |
| 34 | 33 | * user. |
| 35 | 34 | * |
| 36 | 35 | * @since 3.14.0 |
| 37 | - * @since 3.16.0 Added the `$request` parameter. | |
| 38 | 36 | * |
| 39 | - * @param WP_REST_Request|null $request The request object. | |
| 40 | 37 | * @return bool |
| 41 | 38 | */ |
| 42 | - public function is_available_to_current_user( $request = null ): bool { | |
| 39 | + public function is_available_to_current_user(): bool { | |
| 43 | 40 | return current_user_can( |
| 44 | 41 | // phpcs:ignore WordPress.WP.Capabilities.Undetermined |
| 45 | 42 | $this->apply_capability_filters( |
| 46 | 43 | Base_Endpoint::DEFAULT_ACCESS_CAPABILITY |