Skip to content

Commit c553487

Browse files
committed
version 1.0.10 released
1 parent 8996d52 commit c553487

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+2616
-296
lines changed

cbxphpspreadsheet.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
* Plugin Name: CBX PhpSpreadSheet Library
1717
* Plugin URI: https://codeboxr.com/php-spreadsheet-library-wordpress-plugin/
1818
* Description: A pure PHP library for reading and writing spreadsheet files https://phpspreadsheet.readthedocs.io/
19-
* Version: 1.0.9
19+
* Version: 1.0.10
2020
* Requires PHP: 8.1.99
2121
* Author: Codeboxr
2222
* Author URI: https://github.com/PHPOffice/PhpSpreadsheet
@@ -33,7 +33,7 @@
3333
}
3434

3535
defined( 'CBXPHPSPREADSHEET_PLUGIN_NAME' ) or define( 'CBXPHPSPREADSHEET_PLUGIN_NAME', 'cbxphpspreadsheet' );
36-
defined( 'CBXPHPSPREADSHEET_PLUGIN_VERSION' ) or define( 'CBXPHPSPREADSHEET_PLUGIN_VERSION', '1.0.9' );
36+
defined( 'CBXPHPSPREADSHEET_PLUGIN_VERSION' ) or define( 'CBXPHPSPREADSHEET_PLUGIN_VERSION', '1.0.10' );
3737
defined( 'CBXPHPSPREADSHEET_BASE_NAME' ) or define( 'CBXPHPSPREADSHEET_BASE_NAME', plugin_basename( __FILE__ ) );
3838
defined( 'CBXPHPSPREADSHEET_ROOT_PATH' ) or define( 'CBXPHPSPREADSHEET_ROOT_PATH', plugin_dir_path( __FILE__ ) );
3939
defined( 'CBXPHPSPREADSHEET_ROOT_URL' ) or define( 'CBXPHPSPREADSHEET_ROOT_URL', plugin_dir_url( __FILE__ ) );

composer.lock

Lines changed: 99 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/vendor/composer/InstalledVersions.php

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ class InstalledVersions
3232
*/
3333
private static $installed;
3434

35+
/**
36+
* @var bool
37+
*/
38+
private static $installedIsLocalDir;
39+
3540
/**
3641
* @var bool|null
3742
*/
@@ -309,6 +314,12 @@ public static function reload($data)
309314
{
310315
self::$installed = $data;
311316
self::$installedByVendor = array();
317+
318+
// when using reload, we disable the duplicate protection to ensure that self::$installed data is
319+
// always returned, but we cannot know whether it comes from the installed.php in __DIR__ or not,
320+
// so we have to assume it does not, and that may result in duplicate data being returned when listing
321+
// all installed packages for example
322+
self::$installedIsLocalDir = false;
312323
}
313324

314325
/**
@@ -322,19 +333,27 @@ private static function getInstalled()
322333
}
323334

324335
$installed = array();
336+
$copiedLocalDir = false;
325337

326338
if (self::$canGetVendors) {
339+
$selfDir = strtr(__DIR__, '\\', '/');
327340
foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) {
341+
$vendorDir = strtr($vendorDir, '\\', '/');
328342
if (isset(self::$installedByVendor[$vendorDir])) {
329343
$installed[] = self::$installedByVendor[$vendorDir];
330344
} elseif (is_file($vendorDir.'/composer/installed.php')) {
331345
/** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $required */
332346
$required = require $vendorDir.'/composer/installed.php';
333-
$installed[] = self::$installedByVendor[$vendorDir] = $required;
334-
if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) {
335-
self::$installed = $installed[count($installed) - 1];
347+
self::$installedByVendor[$vendorDir] = $required;
348+
$installed[] = $required;
349+
if (self::$installed === null && $vendorDir.'/composer' === $selfDir) {
350+
self::$installed = $required;
351+
self::$installedIsLocalDir = true;
336352
}
337353
}
354+
if (self::$installedIsLocalDir && $vendorDir.'/composer' === $selfDir) {
355+
$copiedLocalDir = true;
356+
}
338357
}
339358
}
340359

@@ -350,7 +369,7 @@ private static function getInstalled()
350369
}
351370
}
352371

353-
if (self::$installed !== array()) {
372+
if (self::$installed !== array() && !$copiedLocalDir) {
354373
$installed[] = self::$installed;
355374
}
356375

lib/vendor/composer/autoload_psr4.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
'PhpOffice\\PhpSpreadsheet\\' => array($vendorDir . '/phpoffice/phpspreadsheet/src/PhpSpreadsheet'),
1515
'MyCLabs\\Enum\\' => array($vendorDir . '/myclabs/php-enum/src'),
1616
'Matrix\\' => array($vendorDir . '/markbaker/matrix/classes/src'),
17+
'Composer\\Pcre\\' => array($vendorDir . '/composer/pcre/src'),
1718
'Complex\\' => array($vendorDir . '/markbaker/complex/classes/src'),
1819
'Cbx\\Phpspreadsheet\\' => array($baseDir . '/includes'),
1920
);

lib/vendor/composer/autoload_static.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ class ComposerStaticInit00806fe69736e9cf42743640feeffa67
3333
),
3434
'C' =>
3535
array (
36+
'Composer\\Pcre\\' => 14,
3637
'Complex\\' => 8,
3738
'Cbx\\Phpspreadsheet\\' => 19,
3839
),
@@ -72,6 +73,10 @@ class ComposerStaticInit00806fe69736e9cf42743640feeffa67
7273
array (
7374
0 => __DIR__ . '/..' . '/markbaker/matrix/classes/src',
7475
),
76+
'Composer\\Pcre\\' =>
77+
array (
78+
0 => __DIR__ . '/..' . '/composer/pcre/src',
79+
),
7580
'Complex\\' =>
7681
array (
7782
0 => __DIR__ . '/..' . '/markbaker/complex/classes/src',

0 commit comments

Comments
 (0)