| @@ -1,10 +1,17 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 4 | + exit; | |
| 5 | +} | |
| 6 | + | |
| 7 | + | |
| 8 | +// phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedFunctionFound -- Legacy public global helper get_ph_pro_features; the established callable name is part of the plugin/extension API and must remain stable. | |
| 3 | 9 | function get_ph_pro_features() |
| 4 | 10 | { |
| 5 | 11 | $features = array(); |
| 6 | 12 | |
| 13 | + // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Read-only public feature metadata refresh; no installation, activation or licensing mutation is performed. | |
| 7 | 14 | if ( false === ( $features = get_transient( 'propertyhive_features' ) ) || isset($_GET['ph_force_get_features']) ) |
| 8 | 15 | { |
| 9 | 16 | // It wasn't there, so regenerate the data and save the transient |
| 10 | 17 | $response = wp_remote_get( |
| @@ -32,8 +39,9 @@ | ||
| 32 | 39 | |
| 33 | 40 | return $features; |
| 34 | 41 | } |
| 35 | 42 | |
| 43 | +// phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedFunctionFound -- Legacy public global helper get_ph_pro_feature; the established callable name is part of the plugin/extension API and must remain stable. | |
| 36 | 44 | function get_ph_pro_feature( $requested_feature ) |
| 37 | 45 | { |
| 38 | 46 | $features = get_ph_pro_features(); |
| 39 | 47 | |