diff --git a/finder-constants.php b/finder-constants.php index e38eb71..0503453 100644 --- a/finder-constants.php +++ b/finder-constants.php @@ -1,7 +1,5 @@ in( array( 'source/vendor/freemius/wordpress-sdk/includes', diff --git a/finder.php b/finder.php index 625e935..d596662 100644 --- a/finder.php +++ b/finder.php @@ -3,29 +3,9 @@ return \StubsGenerator\Finder::create() ->in( array( 'source/vendor/freemius/wordpress-sdk/includes', - 'source/vendor/freemius/wordpress-sdk/templates' ) ) - ->append( - \StubsGenerator\Finder::create() - ->in(['source/vendor/freemius/wordpress-sdk']) - ->files() - ->depth('< 1') - ->path('config.php') - ) - ->append( - \StubsGenerator\Finder::create() - ->in(['source/vendor/freemius/wordpress-sdk/includes/']) - ->files() - ->depth('< 1') - ->path('fs-essential-functions.php') - ) - ->append( - \StubsGenerator\Finder::create() - ->in(['source/vendor/freemius/wordpress-sdk/includes/']) - ->files() - ->depth('< 1') - ->path('require.php') - ) + ->notPath('customizer') + ->notPath('debug') ->append( \StubsGenerator\Finder::create() ->in(['source/vendor/freemius/wordpress-sdk']) @@ -33,7 +13,5 @@ ->depth('< 1') ->path('start.php') ) - ->notPath('customizer') - ->notPath('debug') ->sortByName(true) ; diff --git a/freemius-stubs.php b/freemius-stubs.php index c1cd946..f3ad15c 100644 --- a/freemius-stubs.php +++ b/freemius-stubs.php @@ -5097,9 +5097,9 @@ function should_use_external_pricing() * * * @return array { - * @var bool $success - * @var string $error - * @var string $next_page + * @type bool $success + * @type string $error + * @type string $next_page * } */ private function activate_license($license_key, $sites = array(), $is_marketing_allowed = \null, $blog_id = \null, $plugin_id = \null, $license_owner_id = \null, $is_extensions_tracking_allowed = \null, $is_diagnostic_tracking_allowed = \null) @@ -15849,19 +15849,6 @@ private static function ThrowSquidAclException($pResult = '') } #endregion } -/** - * Initialize Freemius custom debug panels. - * - * @param array $panels Debug bar panels objects - * - * @return array Debug bar panels with your custom panels - */ -function fs_custom_panels_init($panels) -{ -} -function fs_custom_status_init($statuses) -{ -} /** * Get object's public variables. * diff --git a/phpstan.neon b/phpstan.neon index f7901fb..ab03540 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,20 +1,14 @@ parameters: paths: - - freemius-constants-stubs.php - freemius-stubs.php + scanFiles: + - freemius-constants-stubs.php bootstrapFiles: - bootstrap.php level: 5 - tipsOfTheDay: false ignoreErrors: - - '#is always (true|false).#' - '#but return statement is missing\.$#' - '#has an unused parameter#' - '#^(Property|Static property|Method|Static method) \S+ is unused\.$#' - '#is never read, only written\.$#' - '#has invalid (return )?type (WP_Error|WP_Customize_Manager|WP_Theme|WP_User|WP_Site|WP_Upgrader)#' - - '#Parameter \d+ of \S+ is never used\.$#' - - '#Variable \$\S+ might not be defined\.$#' - - '#Function \S+ not found\.#' - - '#tag @var above a method has no effect.#' - \ No newline at end of file