|
@@ 1040-1047 (lines=8) @@
|
| 1037 |
|
sprintf( __( 'Error Details: Jetpack ID is not a scalar. Do not publicly post this error message! %s', 'jetpack' ), $entity ), |
| 1038 |
|
$entity |
| 1039 |
|
); |
| 1040 |
|
} elseif ( preg_match( '/[^0-9]/', $registration_response->jetpack_id ) ) { |
| 1041 |
|
return new \WP_Error( |
| 1042 |
|
'jetpack_id', |
| 1043 |
|
/* translators: %s is an error message string */ |
| 1044 |
|
sprintf( __( 'Error Details: Jetpack ID begins with a numeral. Do not publicly post this error message! %s', 'jetpack' ), $entity ), |
| 1045 |
|
$entity |
| 1046 |
|
); |
| 1047 |
|
} |
| 1048 |
|
|
| 1049 |
|
return $registration_response; |
| 1050 |
|
} |
|
@@ 1767-1779 (lines=13) @@
|
| 1764 |
|
} |
| 1765 |
|
|
| 1766 |
|
// No .test or .local domains. |
| 1767 |
|
if ( preg_match( '#\.(test|local)$#i', $domain ) ) { |
| 1768 |
|
return new \WP_Error( |
| 1769 |
|
'fail_domain_tld', |
| 1770 |
|
sprintf( |
| 1771 |
|
/* translators: %1$s is a domain name. */ |
| 1772 |
|
__( |
| 1773 |
|
'Domain `%1$s` just failed is_usable_domain check as it uses an invalid top level domain.', |
| 1774 |
|
'jetpack' |
| 1775 |
|
), |
| 1776 |
|
$domain |
| 1777 |
|
) |
| 1778 |
|
); |
| 1779 |
|
} |
| 1780 |
|
|
| 1781 |
|
// No WPCOM subdomains. |
| 1782 |
|
if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
|
@@ 1782-1794 (lines=13) @@
|
| 1779 |
|
} |
| 1780 |
|
|
| 1781 |
|
// No WPCOM subdomains. |
| 1782 |
|
if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
| 1783 |
|
return new \WP_Error( |
| 1784 |
|
'fail_subdomain_wpcom', |
| 1785 |
|
sprintf( |
| 1786 |
|
/* translators: %1$s is a domain name. */ |
| 1787 |
|
__( |
| 1788 |
|
'Domain `%1$s` just failed is_usable_domain check as it is a subdomain of WordPress.com.', |
| 1789 |
|
'jetpack' |
| 1790 |
|
), |
| 1791 |
|
$domain |
| 1792 |
|
) |
| 1793 |
|
); |
| 1794 |
|
} |
| 1795 |
|
|
| 1796 |
|
// If PHP was compiled without support for the Filter module (very edge case). |
| 1797 |
|
if ( ! function_exists( 'filter_var' ) ) { |