Skip to content

Commit

Permalink
Fix PHPStan (not including tests)
Browse files Browse the repository at this point in the history
  • Loading branch information
vaurdan committed Oct 21, 2024
1 parent 97f6d25 commit eb61fda
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/rest-api/class-base-endpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ public function get_full_endpoint( string $route = '' ): string {
* @return string
*/
public function get_endpoint_slug(): string {
return $this->api_controller->prefix_route( '' ) . $this->get_endpoint_name();
return $this->api_controller->prefix_route( '' ) . static::get_endpoint_name();
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/rest-api/stats/trait-related-posts.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ public function get_related_posts_of_url( WP_REST_Request $request, string $url
/**
* The raw related posts data, received by the API.
*
* @var array<mixed>|WP_Error $related_posts_request
* @var array<array<string, string>>|WP_Error $related_posts_request
*/
$related_posts_request = $this->content_api->get_related_posts_with_url(
$url,
Expand Down
2 changes: 1 addition & 1 deletion src/services/class-cached-service-endpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ private function get_cache_key( array $args ): string {
$api_service = $this->service_endpoint->api_service;

$cache_key = 'parsely_api_' .
wp_hash( $api_service->get_base_url() ) . '_' .
wp_hash( $api_service->get_api_url() ) . '_' .
wp_hash( $this->get_endpoint() ) . '_' .
wp_hash( (string) wp_json_encode( $args ) );

Expand Down

0 comments on commit eb61fda

Please sign in to comment.