|
@@ 1195-1202 (lines=8) @@
|
| 1192 |
|
sprintf( __( 'Error Details: Jetpack ID is not a scalar. Do not publicly post this error message! %s', 'jetpack' ), $entity ), |
| 1193 |
|
$entity |
| 1194 |
|
); |
| 1195 |
|
} elseif ( preg_match( '/[^0-9]/', $registration_response->jetpack_id ) ) { |
| 1196 |
|
return new \WP_Error( |
| 1197 |
|
'jetpack_id', |
| 1198 |
|
/* translators: %s is an error message string */ |
| 1199 |
|
sprintf( __( 'Error Details: Jetpack ID begins with a numeral. Do not publicly post this error message! %s', 'jetpack' ), $entity ), |
| 1200 |
|
$entity |
| 1201 |
|
); |
| 1202 |
|
} |
| 1203 |
|
|
| 1204 |
|
return $registration_response; |
| 1205 |
|
} |
|
@@ 1911-1923 (lines=13) @@
|
| 1908 |
|
} |
| 1909 |
|
|
| 1910 |
|
// No .test or .local domains. |
| 1911 |
|
if ( preg_match( '#\.(test|local)$#i', $domain ) ) { |
| 1912 |
|
return new \WP_Error( |
| 1913 |
|
'fail_domain_tld', |
| 1914 |
|
sprintf( |
| 1915 |
|
/* translators: %1$s is a domain name. */ |
| 1916 |
|
__( |
| 1917 |
|
'Domain `%1$s` just failed is_usable_domain check as it uses an invalid top level domain.', |
| 1918 |
|
'jetpack' |
| 1919 |
|
), |
| 1920 |
|
$domain |
| 1921 |
|
) |
| 1922 |
|
); |
| 1923 |
|
} |
| 1924 |
|
|
| 1925 |
|
// No WPCOM subdomains. |
| 1926 |
|
if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
|
@@ 1926-1938 (lines=13) @@
|
| 1923 |
|
} |
| 1924 |
|
|
| 1925 |
|
// No WPCOM subdomains. |
| 1926 |
|
if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
| 1927 |
|
return new \WP_Error( |
| 1928 |
|
'fail_subdomain_wpcom', |
| 1929 |
|
sprintf( |
| 1930 |
|
/* translators: %1$s is a domain name. */ |
| 1931 |
|
__( |
| 1932 |
|
'Domain `%1$s` just failed is_usable_domain check as it is a subdomain of WordPress.com.', |
| 1933 |
|
'jetpack' |
| 1934 |
|
), |
| 1935 |
|
$domain |
| 1936 |
|
) |
| 1937 |
|
); |
| 1938 |
|
} |
| 1939 |
|
|
| 1940 |
|
// If PHP was compiled without support for the Filter module (very edge case). |
| 1941 |
|
if ( ! function_exists( 'filter_var' ) ) { |