Skip to content

Commit

Permalink
Update Meta Box, do not check Meta Box Builder license
Browse files Browse the repository at this point in the history
  • Loading branch information
rilwis committed Jan 10, 2025
1 parent b76955f commit d1f5ea7
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 63 deletions.
8 changes: 4 additions & 4 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions modules/meta-box/src/Updater/Checker.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ public function get_extensions(): array {
$extensions = [
'mb-admin-columns',
'mb-blocks',
'mb-core',
'mb-custom-table',
'mb-frontend-submission',
'mb-revision',
Expand All @@ -44,8 +43,6 @@ public function get_extensions(): array {
'mb-user-meta',
'mb-user-profile',
'mb-views',
'meta-box-aio',
'meta-box-builder',
'meta-box-columns',
'meta-box-conditional-logic',
'meta-box-geolocation',
Expand All @@ -58,6 +55,9 @@ public function get_extensions(): array {
'mb-favorite-posts',
'mb-testimonials',
'mb-user-avatar',

'mb-core',
'meta-box-aio',
];
$plugins = get_plugins();
$plugins = array_map( 'dirname', array_keys( $plugins ) );
Expand All @@ -77,6 +77,7 @@ private function get_free_extensions(): array {

$extensions = [
'meta-box-lite',
'meta-box-builder',
];
$plugins = get_plugins();
$plugins = array_map( 'dirname', array_keys( $plugins ) );
Expand Down
17 changes: 2 additions & 15 deletions vendor/autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,8 @@
// autoload.php @generated by Composer

if (PHP_VERSION_ID < 50600) {
if (!headers_sent()) {
header('HTTP/1.1 500 Internal Server Error');
}
$err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
if (!ini_get('display_errors')) {
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
fwrite(STDERR, $err);
} elseif (!headers_sent()) {
echo $err;
}
}
trigger_error(
$err,
E_USER_ERROR
);
echo 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
exit(1);
}

require_once __DIR__ . '/composer/autoload_real.php';
Expand Down
37 changes: 14 additions & 23 deletions vendor/composer/ClassLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,6 @@
*/
class ClassLoader
{
/** @var \Closure(string):void */
private static $includeFile;

/** @var ?string */
private $vendorDir;

Expand Down Expand Up @@ -109,7 +106,6 @@ class ClassLoader
public function __construct($vendorDir = null)
{
$this->vendorDir = $vendorDir;
self::initializeIncludeClosure();
}

/**
Expand Down Expand Up @@ -429,7 +425,7 @@ public function unregister()
public function loadClass($class)
{
if ($file = $this->findFile($class)) {
(self::$includeFile)($file);
includeFile($file);

return true;
}
Expand Down Expand Up @@ -559,23 +555,18 @@ private function findFileWithExtension($class, $ext)

return false;
}
}

private static function initializeIncludeClosure(): void
{
if (self::$includeFile !== null) {
return;
}

/**
* Scope isolated include.
*
* Prevents access to $this/self from included files.
*
* @param string $file
* @return void
*/
self::$includeFile = static function($file) {
include $file;
};
}
/**
* Scope isolated include.
*
* Prevents access to $this/self from included files.
*
* @param string $file
* @return void
* @private
*/
function includeFile($file)
{
include $file;
}
27 changes: 17 additions & 10 deletions vendor/composer/autoload_real.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,25 @@ public static function getLoader()

$loader->register(false);

$filesToLoad = \Composer\Autoload\ComposerStaticInitff1056f71c6dba41d243124bfd07b96d::$files;
$requireFile = static function ($fileIdentifier, $file) {
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;

require $file;
}
};
foreach ($filesToLoad as $fileIdentifier => $file) {
($requireFile)($fileIdentifier, $file);
$includeFiles = \Composer\Autoload\ComposerStaticInitff1056f71c6dba41d243124bfd07b96d::$files;
foreach ($includeFiles as $fileIdentifier => $file) {
composerRequireff1056f71c6dba41d243124bfd07b96d($fileIdentifier, $file);
}

return $loader;
}
}

/**
* @param string $fileIdentifier
* @param string $file
* @return void
*/
function composerRequireff1056f71c6dba41d243124bfd07b96d($fileIdentifier, $file)
{
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;

require $file;
}
}
8 changes: 4 additions & 4 deletions vendor/composer/installed.json
Original file line number Diff line number Diff line change
Expand Up @@ -547,12 +547,12 @@
"source": {
"type": "git",
"url": "[email protected]:wpmetabox/mb-custom-post-type.git",
"reference": "11c1a2b8e897812435eecfb049371bdc8965f69f"
"reference": "3fdce0d3dde2ab5bc46176d3682d6c4b8fdcb8d1"
},
"require": {
"meta-box/support": "dev-master"
},
"time": "2024-12-25T09:00:31+00:00",
"time": "2025-01-08T09:16:35+00:00",
"default-branch": true,
"type": "wordpress-plugin",
"installation-source": "source",
Expand Down Expand Up @@ -824,15 +824,15 @@
"source": {
"type": "git",
"url": "[email protected]:wpmetabox/meta-box.git",
"reference": "9e243e8d8cbfbd3ef69218a441619394374a1708"
"reference": "66134565e02393ac6483369cc09090a3f204a3ca"
},
"require": {
"meta-box/support": "dev-master"
},
"require-dev": {
"phpunit/phpunit": "^11.3"
},
"time": "2025-01-09T08:25:10+00:00",
"time": "2025-01-10T05:10:05+00:00",
"default-branch": true,
"type": "wordpress-plugin",
"extra": {
Expand Down
8 changes: 4 additions & 4 deletions vendor/composer/installed.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
'name' => '__root__',
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => 'aa429e6fa625dc45861768197aa221e03522f43b',
'reference' => 'b76955fe63f73d659b04d94313c6325d79a9f19a',
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
Expand All @@ -13,7 +13,7 @@
'__root__' => array(
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => 'aa429e6fa625dc45861768197aa221e03522f43b',
'reference' => 'b76955fe63f73d659b04d94313c6325d79a9f19a',
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
Expand Down Expand Up @@ -140,7 +140,7 @@
'wpmetabox/mb-custom-post-type' => array(
'pretty_version' => 'dev-master',
'version' => 'dev-master',
'reference' => '11c1a2b8e897812435eecfb049371bdc8965f69f',
'reference' => '3fdce0d3dde2ab5bc46176d3682d6c4b8fdcb8d1',
'type' => 'wordpress-plugin',
'install_path' => __DIR__ . '/../../modules/mb-custom-post-type',
'aliases' => array(
Expand Down Expand Up @@ -206,7 +206,7 @@
'wpmetabox/meta-box' => array(
'pretty_version' => 'dev-master',
'version' => 'dev-master',
'reference' => '9e243e8d8cbfbd3ef69218a441619394374a1708',
'reference' => '66134565e02393ac6483369cc09090a3f204a3ca',
'type' => 'wordpress-plugin',
'install_path' => __DIR__ . '/../../modules/meta-box',
'aliases' => array(
Expand Down

0 comments on commit d1f5ea7

Please sign in to comment.