jetpack
Last commit date
3rd-party
2 years ago
_inc
2 years ago
css
2 years ago
extensions
2 years ago
images
2 years ago
jetpack_vendor
16 hours ago
json-endpoints
2 years ago
modules
1 year ago
sal
2 years ago
src
3 years ago
vendor
2 years ago
views
3 years ago
CHANGELOG.md
2 years ago
LICENSE.txt
5 years ago
SECURITY.md
2 years ago
class-jetpack-connection-status.php
2 years ago
class-jetpack-connection-widget.php
2 years ago
class-jetpack-gallery-settings.php
3 years ago
class-jetpack-pre-connection-jitms.php
4 years ago
class-jetpack-recommendations-banner.php
2 years ago
class-jetpack-stats-dashboard-widget.php
2 years ago
class-jetpack-wizard-banner.php
5 years ago
class-jetpack-xmlrpc-methods.php
2 years ago
class.frame-nonce-preview.php
4 years ago
class.jetpack-admin.php
2 years ago
class.jetpack-affiliate.php
2 years ago
class.jetpack-autoupdate.php
2 years ago
class.jetpack-bbpress-json-api.compat.php
2 years ago
class.jetpack-boost-modules.php
3 years ago
class.jetpack-cli.php
2 years ago
class.jetpack-client-server.php
4 years ago
class.jetpack-connection-banner.php
2 years ago
class.jetpack-data.php
2 years ago
class.jetpack-gutenberg.php
2 years ago
class.jetpack-heartbeat.php
2 years ago
class.jetpack-idc.php
5 years ago
class.jetpack-modules-list-table.php
2 years ago
class.jetpack-network-sites-list-table.php
2 years ago
class.jetpack-network.php
3 years ago
class.jetpack-plan.php
3 years ago
class.jetpack-post-images.php
2 years ago
class.jetpack-twitter-cards.php
2 years ago
class.jetpack-user-agent.php
2 years ago
class.jetpack.php
2 years ago
class.json-api-endpoints.php
2 years ago
class.json-api.php
2 years ago
class.photon.php
3 years ago
composer.json
2 years ago
enhanced-open-graph.php
3 years ago
functions.compat.php
2 years ago
functions.cookies.php
2 years ago
functions.global.php
2 years ago
functions.is-mobile.php
2 years ago
functions.opengraph.php
2 years ago
functions.photon.php
2 years ago
jetpack.php
16 hours ago
json-api-config.php
3 years ago
json-endpoints.php
2 years ago
load-jetpack.php
3 years ago
locales.php
4 years ago
readme.txt
16 hours ago
uninstall.php
2 years ago
wpml-config.xml
4 years ago
class.jetpack-boost-modules.php
56 lines
| 1 | <?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName |
| 2 | |
| 3 | /** |
| 4 | * Jetpack Boost Active Modules |
| 5 | * |
| 6 | * Since the speed scores API will only be used in the Jetpack plugin if Jetpack Boost is uninstalled |
| 7 | * all we need is to pass along this placeholder class for the modules that essentially tells the API |
| 8 | * the user doesn't have any Boost modules active. |
| 9 | * |
| 10 | * @package automattic/jetpack |
| 11 | */ |
| 12 | |
| 13 | /** |
| 14 | * Jetpack Boost Modules |
| 15 | */ |
| 16 | class Jetpack_Boost_Modules { |
| 17 | |
| 18 | /** |
| 19 | * Holds the singleton instance of the class |
| 20 | * |
| 21 | * @var Jetpack_Boost_Modules |
| 22 | */ |
| 23 | private static $instance = false; |
| 24 | |
| 25 | /** |
| 26 | * Singleton |
| 27 | * |
| 28 | * @static |
| 29 | * @return Jetpack_Boost_Modules |
| 30 | */ |
| 31 | public static function init() { |
| 32 | if ( ! self::$instance ) { |
| 33 | self::$instance = new Jetpack_Boost_Modules(); |
| 34 | } |
| 35 | |
| 36 | return self::$instance; |
| 37 | } |
| 38 | /** |
| 39 | * Returns status of all active boost modules |
| 40 | * |
| 41 | * @return array - An empty array. The user will never have active modules when using the Boost Score API |
| 42 | */ |
| 43 | public function get_status() { |
| 44 | return array(); |
| 45 | } |
| 46 | |
| 47 | /** |
| 48 | * Returns whether or not the user has active modules |
| 49 | * |
| 50 | * @return false - The user will never have active modules when using the Boost Score API |
| 51 | */ |
| 52 | public function have_enabled_modules() { |
| 53 | return false; |
| 54 | } |
| 55 | } |
| 56 |