| @@ -407,9 +407,9 @@ | ||
| 407 | 407 | |
| 408 | 408 | $pWPRemoteArgs = array( |
| 409 | 409 | 'method' => strtoupper( $pMethod ), |
| 410 | 410 | 'connect_timeout' => 10, |
| 411 | - 'timeout' => 60, | |
| 411 | + 'timeout' => WP_FS__API_TIMEOUT, | |
| 412 | 412 | 'follow_redirects' => true, |
| 413 | 413 | 'redirection' => 5, |
| 414 | 414 | 'user-agent' => $user_agent, |
| 415 | 415 | 'blocking' => true, |
| @@ -472,10 +472,14 @@ | ||
| 472 | 472 | * @author Vova Feldman (@svovaf) |
| 473 | 473 | */ |
| 474 | 474 | if ( filter_var( $matches[1], FILTER_VALIDATE_IP ) ) { |
| 475 | 475 | if ( strlen( inet_pton( $matches[1] ) ) === 16 ) { |
| 476 | -// error_log('Invalid IPv6 configuration on server, Please disable or get native IPv6 on your server.'); | |
| 477 | - // Hook to an action triggered just before cURL is executed to resolve the IP version to v4. | |
| 476 | + /** | |
| 477 | + * error_log('Invalid IPv6 configuration on server, Please disable or get native IPv6 on your server.'); | |
| 478 | + * Hook to an action triggered just before cURL is executed to resolve the IP version to v4. | |
| 479 | + * | |
| 480 | + * @phpstan-ignore-next-line | |
| 481 | + */ | |
| 478 | 482 | add_action( 'http_api_curl', 'Freemius_Api_WordPress::CurlResolveToIPv4', 10, 1 ); |
| 479 | 483 | |
| 480 | 484 | // Re-run request. |
| 481 | 485 | $result = self::ExecuteRequest( $request_url, $pWPRemoteArgs ); |