@@ 1349-1361 (lines=13) @@ | ||
1346 | } |
|
1347 | ||
1348 | // No .test or .local domains. |
|
1349 | if ( preg_match( '#\.(test|local)$#i', $domain ) ) { |
|
1350 | return new \WP_Error( |
|
1351 | 'fail_domain_tld', |
|
1352 | sprintf( |
|
1353 | /* translators: %1$s is a domain name. */ |
|
1354 | __( |
|
1355 | 'Domain `%1$s` just failed is_usable_domain check as it uses an invalid top level domain.', |
|
1356 | 'jetpack' |
|
1357 | ), |
|
1358 | $domain |
|
1359 | ) |
|
1360 | ); |
|
1361 | } |
|
1362 | ||
1363 | // No WPCOM subdomains. |
|
1364 | if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
|
@@ 1364-1376 (lines=13) @@ | ||
1361 | } |
|
1362 | ||
1363 | // No WPCOM subdomains. |
|
1364 | if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { |
|
1365 | return new \WP_Error( |
|
1366 | 'fail_subdomain_wpcom', |
|
1367 | sprintf( |
|
1368 | /* translators: %1$s is a domain name. */ |
|
1369 | __( |
|
1370 | 'Domain `%1$s` just failed is_usable_domain check as it is a subdomain of WordPress.com.', |
|
1371 | 'jetpack' |
|
1372 | ), |
|
1373 | $domain |
|
1374 | ) |
|
1375 | ); |
|
1376 | } |
|
1377 | ||
1378 | // If PHP was compiled without support for the Filter module (very edge case). |
|
1379 | if ( ! function_exists( 'filter_var' ) ) { |