Changeset 2933625
- Timestamp:
- 07/04/2023 04:38:18 AM (3 years ago)
- Location:
- smartpay
- Files:
-
- 18 edited
- 1 copied
-
tags/2.7.5 (copied) (copied from smartpay/trunk)
-
tags/2.7.5/app/Modules/Gateway/Gateways/PaypalStandard.php (modified) (1 diff)
-
tags/2.7.5/readme.txt (modified) (2 diffs)
-
tags/2.7.5/smartpay.php (modified) (2 diffs)
-
tags/2.7.5/vendor/autoload.php (modified) (1 diff)
-
tags/2.7.5/vendor/composer/ClassLoader.php (modified) (27 diffs)
-
tags/2.7.5/vendor/composer/InstalledVersions.php (modified) (4 diffs)
-
tags/2.7.5/vendor/composer/autoload_real.php (modified) (3 diffs)
-
tags/2.7.5/vendor/composer/autoload_static.php (modified) (2 diffs)
-
tags/2.7.5/vendor/composer/installed.php (modified) (2 diffs)
-
trunk/app/Modules/Gateway/Gateways/PaypalStandard.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/smartpay.php (modified) (2 diffs)
-
trunk/vendor/autoload.php (modified) (1 diff)
-
trunk/vendor/composer/ClassLoader.php (modified) (27 diffs)
-
trunk/vendor/composer/InstalledVersions.php (modified) (4 diffs)
-
trunk/vendor/composer/autoload_real.php (modified) (3 diffs)
-
trunk/vendor/composer/autoload_static.php (modified) (2 diffs)
-
trunk/vendor/composer/installed.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
smartpay/tags/2.7.5/app/Modules/Gateway/Gateways/PaypalStandard.php
r2739844 r2933625 88 88 } 89 89 90 $payment_price = number_format($paymentData['amount'], 2 );90 $payment_price = number_format($paymentData['amount'], 2, '.', ''); 91 91 92 92 $default_args = [ -
smartpay/tags/2.7.5/readme.txt
r2845050 r2933625 3 3 Tags: download manager, digital product, donation, ecommerce, stripe, paypal, paddle, document manager, file manager, download protection, recurring payment, donations, donation plugin, wordpress donation plugin, wp donation, fundraising, fundraiser, crowdfunding, wordpress donations, gutenberg, gutenberg donations, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations, bkash, bkash payment, 4 4 Requires at least: 4.9 5 Tested up to: 6. 1.15 Tested up to: 6.2.2 6 6 Requires PHP: 7.4.0 7 Stable Tag: 2.7. 47 Stable Tag: 2.7.5 8 8 License: GNU Version 2 or later 9 9 … … 123 123 124 124 == Changelog == 125 = [2.7.5] = 126 * Fix - PayPal amount error for bigger amount 127 125 128 = [2.7.4] = 126 129 * Fix - Coupon is not reduced price for both From and Product. -
smartpay/tags/2.7.5/smartpay.php
r2845050 r2933625 6 6 * Plugin URI: https://wpsmartpay.com/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash 7 7 * Tags: download manager, digital product, donation, ecommerce, paddle, stripe, paypal, document manager, file manager, download protection, recurring payment, donations, donation plugin, wordpress donation plugin, wp donation, fundraising, fundraiser, crowdfunding, wordpress donations, gutenberg, gutenberg donations, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations, bkash, bkash payment, 8 * Version: 2.7. 48 * Version: 2.7.5 9 9 * Author: WPSmartPay 10 10 * Author URI: https://wpsmartpay.com/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash … … 28 28 defined('ABSPATH') || exit; 29 29 30 define('SMARTPAY_VERSION', '2.7. 4');30 define('SMARTPAY_VERSION', '2.7.5'); 31 31 define('SMARTPAY_PLUGIN_FILE', __FILE__); 32 32 define('SMARTPAY_PLUGIN_ASSETS', plugins_url('public', __FILE__)); -
smartpay/tags/2.7.5/vendor/autoload.php
r2845050 r2933625 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15::getLoader();25 return ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197::getLoader(); -
smartpay/tags/2.7.5/vendor/composer/ClassLoader.php
r2845050 r2933625 46 46 private static $includeFile; 47 47 48 /** @var ?string*/48 /** @var string|null */ 49 49 private $vendorDir; 50 50 51 51 // PSR-4 52 52 /** 53 * @var array[] 54 * @psalm-var array<string, array<string, int>> 53 * @var array<string, array<string, int>> 55 54 */ 56 55 private $prefixLengthsPsr4 = array(); 57 56 /** 58 * @var array[] 59 * @psalm-var array<string, array<int, string>> 57 * @var array<string, list<string>> 60 58 */ 61 59 private $prefixDirsPsr4 = array(); 62 60 /** 63 * @var array[] 64 * @psalm-var array<string, string> 61 * @var list<string> 65 62 */ 66 63 private $fallbackDirsPsr4 = array(); … … 68 65 // PSR-0 69 66 /** 70 * @var array[] 71 * @psalm-var array<string, array<string, string[]>> 67 * List of PSR-0 prefixes 68 * 69 * Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2'))) 70 * 71 * @var array<string, array<string, list<string>>> 72 72 */ 73 73 private $prefixesPsr0 = array(); 74 74 /** 75 * @var array[] 76 * @psalm-var array<string, string> 75 * @var list<string> 77 76 */ 78 77 private $fallbackDirsPsr0 = array(); … … 82 81 83 82 /** 84 * @var string[] 85 * @psalm-var array<string, string> 83 * @var array<string, string> 86 84 */ 87 85 private $classMap = array(); … … 91 89 92 90 /** 93 * @var bool[] 94 * @psalm-var array<string, bool> 91 * @var array<string, bool> 95 92 */ 96 93 private $missingClasses = array(); 97 94 98 /** @var ?string*/95 /** @var string|null */ 99 96 private $apcuPrefix; 100 97 101 98 /** 102 * @var self[]99 * @var array<string, self> 103 100 */ 104 101 private static $registeredLoaders = array(); 105 102 106 103 /** 107 * @param ?string$vendorDir104 * @param string|null $vendorDir 108 105 */ 109 106 public function __construct($vendorDir = null) … … 114 111 115 112 /** 116 * @return string[]113 * @return array<string, list<string>> 117 114 */ 118 115 public function getPrefixes() … … 126 123 127 124 /** 128 * @return array[] 129 * @psalm-return array<string, array<int, string>> 125 * @return array<string, list<string>> 130 126 */ 131 127 public function getPrefixesPsr4() … … 135 131 136 132 /** 137 * @return array[] 138 * @psalm-return array<string, string> 133 * @return list<string> 139 134 */ 140 135 public function getFallbackDirs() … … 144 139 145 140 /** 146 * @return array[] 147 * @psalm-return array<string, string> 141 * @return list<string> 148 142 */ 149 143 public function getFallbackDirsPsr4() … … 153 147 154 148 /** 155 * @return string[] Array of classname => path 156 * @psalm-return array<string, string> 149 * @return array<string, string> Array of classname => path 157 150 */ 158 151 public function getClassMap() … … 162 155 163 156 /** 164 * @param string[] $classMap Class to filename map 165 * @psalm-param array<string, string> $classMap 157 * @param array<string, string> $classMap Class to filename map 166 158 * 167 159 * @return void … … 180 172 * appending or prepending to the ones previously set for this prefix. 181 173 * 182 * @param string $prefix The prefix183 * @param string[]|string $paths The PSR-0 root directories184 * @param bool $prepend Whether to prepend the directories174 * @param string $prefix The prefix 175 * @param list<string>|string $paths The PSR-0 root directories 176 * @param bool $prepend Whether to prepend the directories 185 177 * 186 178 * @return void … … 188 180 public function add($prefix, $paths, $prepend = false) 189 181 { 182 $paths = (array) $paths; 190 183 if (!$prefix) { 191 184 if ($prepend) { 192 185 $this->fallbackDirsPsr0 = array_merge( 193 (array)$paths,186 $paths, 194 187 $this->fallbackDirsPsr0 195 188 ); … … 197 190 $this->fallbackDirsPsr0 = array_merge( 198 191 $this->fallbackDirsPsr0, 199 (array)$paths192 $paths 200 193 ); 201 194 } … … 206 199 $first = $prefix[0]; 207 200 if (!isset($this->prefixesPsr0[$first][$prefix])) { 208 $this->prefixesPsr0[$first][$prefix] = (array)$paths;201 $this->prefixesPsr0[$first][$prefix] = $paths; 209 202 210 203 return; … … 212 205 if ($prepend) { 213 206 $this->prefixesPsr0[$first][$prefix] = array_merge( 214 (array)$paths,207 $paths, 215 208 $this->prefixesPsr0[$first][$prefix] 216 209 ); … … 218 211 $this->prefixesPsr0[$first][$prefix] = array_merge( 219 212 $this->prefixesPsr0[$first][$prefix], 220 (array)$paths213 $paths 221 214 ); 222 215 } … … 227 220 * appending or prepending to the ones previously set for this namespace. 228 221 * 229 * @param string $prefix The prefix/namespace, with trailing '\\'230 * @param string[]|string $paths The PSR-4 base directories231 * @param bool $prepend Whether to prepend the directories222 * @param string $prefix The prefix/namespace, with trailing '\\' 223 * @param list<string>|string $paths The PSR-4 base directories 224 * @param bool $prepend Whether to prepend the directories 232 225 * 233 226 * @throws \InvalidArgumentException … … 237 230 public function addPsr4($prefix, $paths, $prepend = false) 238 231 { 232 $paths = (array) $paths; 239 233 if (!$prefix) { 240 234 // Register directories for the root namespace. 241 235 if ($prepend) { 242 236 $this->fallbackDirsPsr4 = array_merge( 243 (array)$paths,237 $paths, 244 238 $this->fallbackDirsPsr4 245 239 ); … … 247 241 $this->fallbackDirsPsr4 = array_merge( 248 242 $this->fallbackDirsPsr4, 249 (array)$paths243 $paths 250 244 ); 251 245 } … … 257 251 } 258 252 $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; 259 $this->prefixDirsPsr4[$prefix] = (array)$paths;253 $this->prefixDirsPsr4[$prefix] = $paths; 260 254 } elseif ($prepend) { 261 255 // Prepend directories for an already registered namespace. 262 256 $this->prefixDirsPsr4[$prefix] = array_merge( 263 (array)$paths,257 $paths, 264 258 $this->prefixDirsPsr4[$prefix] 265 259 ); … … 268 262 $this->prefixDirsPsr4[$prefix] = array_merge( 269 263 $this->prefixDirsPsr4[$prefix], 270 (array)$paths264 $paths 271 265 ); 272 266 } … … 277 271 * replacing any others previously set for this prefix. 278 272 * 279 * @param string $prefix The prefix280 * @param string[]|string $paths The PSR-0 base directories273 * @param string $prefix The prefix 274 * @param list<string>|string $paths The PSR-0 base directories 281 275 * 282 276 * @return void … … 295 289 * replacing any others previously set for this namespace. 296 290 * 297 * @param string $prefix The prefix/namespace, with trailing '\\'298 * @param string[]|string $paths The PSR-4 base directories291 * @param string $prefix The prefix/namespace, with trailing '\\' 292 * @param list<string>|string $paths The PSR-4 base directories 299 293 * 300 294 * @throws \InvalidArgumentException … … 430 424 { 431 425 if ($file = $this->findFile($class)) { 432 (self::$includeFile)($file); 426 $includeFile = self::$includeFile; 427 $includeFile($file); 433 428 434 429 return true; … … 481 476 482 477 /** 483 * Returns the currently registered loaders indexed by their corresponding vendor directories.484 * 485 * @return self[]478 * Returns the currently registered loaders keyed by their corresponding vendor directories. 479 * 480 * @return array<string, self> 486 481 */ 487 482 public static function getRegisteredLoaders() … … 561 556 } 562 557 563 private static function initializeIncludeClosure(): void 558 /** 559 * @return void 560 */ 561 private static function initializeIncludeClosure() 564 562 { 565 563 if (self::$includeFile !== null) { … … 575 573 * @return void 576 574 */ 577 self::$includeFile = static function($file) {575 self::$includeFile = \Closure::bind(static function($file) { 578 576 include $file; 579 } ;577 }, null, null); 580 578 } 581 579 } -
smartpay/tags/2.7.5/vendor/composer/InstalledVersions.php
r2739833 r2933625 99 99 foreach (self::getInstalled() as $installed) { 100 100 if (isset($installed['versions'][$packageName])) { 101 return $includeDevRequirements || empty($installed['versions'][$packageName]['dev_requirement']);101 return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false; 102 102 } 103 103 } … … 120 120 public static function satisfies(VersionParser $parser, $packageName, $constraint) 121 121 { 122 $constraint = $parser->parseConstraints( $constraint);122 $constraint = $parser->parseConstraints((string) $constraint); 123 123 $provided = $parser->parseConstraints(self::getVersionRanges($packageName)); 124 124 … … 329 329 $installed[] = self::$installedByVendor[$vendorDir]; 330 330 } elseif (is_file($vendorDir.'/composer/installed.php')) { 331 $installed[] = self::$installedByVendor[$vendorDir] = require $vendorDir.'/composer/installed.php'; 331 /** @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 */ 332 $required = require $vendorDir.'/composer/installed.php'; 333 $installed[] = self::$installedByVendor[$vendorDir] = $required; 332 334 if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) { 333 335 self::$installed = $installed[count($installed) - 1]; … … 341 343 // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 342 344 if (substr(__DIR__, -8, 1) !== 'C') { 343 self::$installed = require __DIR__ . '/installed.php'; 345 /** @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 */ 346 $required = require __DIR__ . '/installed.php'; 347 self::$installed = $required; 344 348 } else { 345 349 self::$installed = array(); 346 350 } 347 351 } 348 $installed[] = self::$installed; 352 353 if (self::$installed !== array()) { 354 $installed[] = self::$installed; 355 } 349 356 350 357 return $installed; -
smartpay/tags/2.7.5/vendor/composer/autoload_real.php
r2845050 r2933625 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb155 class ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197 6 6 { 7 7 private static $loader; … … 25 25 require __DIR__ . '/platform_check.php'; 26 26 27 spl_autoload_register(array('ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15', 'loadClassLoader'), true, true);27 spl_autoload_register(array('ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197', 'loadClassLoader'), true, true); 28 28 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 29 spl_autoload_unregister(array('ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15', 'loadClassLoader'));29 spl_autoload_unregister(array('ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197', 'loadClassLoader')); 30 30 31 31 require __DIR__ . '/autoload_static.php'; 32 call_user_func(\Composer\Autoload\ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::getInitializer($loader));32 call_user_func(\Composer\Autoload\ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::getInitializer($loader)); 33 33 34 34 $loader->register(true); 35 35 36 $filesToLoad = \Composer\Autoload\ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$files;37 $requireFile = static function ($fileIdentifier, $file) {36 $filesToLoad = \Composer\Autoload\ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$files; 37 $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { 38 38 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { 39 39 $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; … … 41 41 require $file; 42 42 } 43 } ;43 }, null, null); 44 44 foreach ($filesToLoad as $fileIdentifier => $file) { 45 ($requireFile)($fileIdentifier, $file);45 $requireFile($fileIdentifier, $file); 46 46 } 47 47 -
smartpay/tags/2.7.5/vendor/composer/autoload_static.php
r2845050 r2933625 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit 1d7f05993c4428b947a11e109eefbb157 class ComposerStaticInitf3f4d46712f95c49e5003fb08b602197 8 8 { 9 9 public static $files = array ( … … 111 111 { 112 112 return \Closure::bind(function () use ($loader) { 113 $loader->prefixLengthsPsr4 = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$prefixLengthsPsr4;114 $loader->prefixDirsPsr4 = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$prefixDirsPsr4;115 $loader->classMap = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$classMap;113 $loader->prefixLengthsPsr4 = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$prefixLengthsPsr4; 114 $loader->prefixDirsPsr4 = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$prefixDirsPsr4; 115 $loader->classMap = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$classMap; 116 116 117 117 }, null, ClassLoader::class); -
smartpay/tags/2.7.5/vendor/composer/installed.php
r2845050 r2933625 2 2 'root' => array( 3 3 'name' => 'wp-smartpay/core', 4 'pretty_version' => 'v2.7. 4.2',5 'version' => '2.7. 4.2',6 'reference' => ' fb9868af7fb284ff2294af0f2279632bfe7c7105',4 'pretty_version' => 'v2.7.5', 5 'version' => '2.7.5.0', 6 'reference' => '1cb87ef2823c1de984b2c2100609c505c06fcc2b', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 108 108 ), 109 109 'wp-smartpay/core' => array( 110 'pretty_version' => 'v2.7. 4.2',111 'version' => '2.7. 4.2',112 'reference' => ' fb9868af7fb284ff2294af0f2279632bfe7c7105',110 'pretty_version' => 'v2.7.5', 111 'version' => '2.7.5.0', 112 'reference' => '1cb87ef2823c1de984b2c2100609c505c06fcc2b', 113 113 'type' => 'library', 114 114 'install_path' => __DIR__ . '/../../', -
smartpay/trunk/app/Modules/Gateway/Gateways/PaypalStandard.php
r2739844 r2933625 88 88 } 89 89 90 $payment_price = number_format($paymentData['amount'], 2 );90 $payment_price = number_format($paymentData['amount'], 2, '.', ''); 91 91 92 92 $default_args = [ -
smartpay/trunk/readme.txt
r2845050 r2933625 3 3 Tags: download manager, digital product, donation, ecommerce, stripe, paypal, paddle, document manager, file manager, download protection, recurring payment, donations, donation plugin, wordpress donation plugin, wp donation, fundraising, fundraiser, crowdfunding, wordpress donations, gutenberg, gutenberg donations, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations, bkash, bkash payment, 4 4 Requires at least: 4.9 5 Tested up to: 6. 1.15 Tested up to: 6.2.2 6 6 Requires PHP: 7.4.0 7 Stable Tag: 2.7. 47 Stable Tag: 2.7.5 8 8 License: GNU Version 2 or later 9 9 … … 123 123 124 124 == Changelog == 125 = [2.7.5] = 126 * Fix - PayPal amount error for bigger amount 127 125 128 = [2.7.4] = 126 129 * Fix - Coupon is not reduced price for both From and Product. -
smartpay/trunk/smartpay.php
r2845050 r2933625 6 6 * Plugin URI: https://wpsmartpay.com/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash 7 7 * Tags: download manager, digital product, donation, ecommerce, paddle, stripe, paypal, document manager, file manager, download protection, recurring payment, donations, donation plugin, wordpress donation plugin, wp donation, fundraising, fundraiser, crowdfunding, wordpress donations, gutenberg, gutenberg donations, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations, bkash, bkash payment, 8 * Version: 2.7. 48 * Version: 2.7.5 9 9 * Author: WPSmartPay 10 10 * Author URI: https://wpsmartpay.com/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash … … 28 28 defined('ABSPATH') || exit; 29 29 30 define('SMARTPAY_VERSION', '2.7. 4');30 define('SMARTPAY_VERSION', '2.7.5'); 31 31 define('SMARTPAY_PLUGIN_FILE', __FILE__); 32 32 define('SMARTPAY_PLUGIN_ASSETS', plugins_url('public', __FILE__)); -
smartpay/trunk/vendor/autoload.php
r2845050 r2933625 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15::getLoader();25 return ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197::getLoader(); -
smartpay/trunk/vendor/composer/ClassLoader.php
r2845050 r2933625 46 46 private static $includeFile; 47 47 48 /** @var ?string*/48 /** @var string|null */ 49 49 private $vendorDir; 50 50 51 51 // PSR-4 52 52 /** 53 * @var array[] 54 * @psalm-var array<string, array<string, int>> 53 * @var array<string, array<string, int>> 55 54 */ 56 55 private $prefixLengthsPsr4 = array(); 57 56 /** 58 * @var array[] 59 * @psalm-var array<string, array<int, string>> 57 * @var array<string, list<string>> 60 58 */ 61 59 private $prefixDirsPsr4 = array(); 62 60 /** 63 * @var array[] 64 * @psalm-var array<string, string> 61 * @var list<string> 65 62 */ 66 63 private $fallbackDirsPsr4 = array(); … … 68 65 // PSR-0 69 66 /** 70 * @var array[] 71 * @psalm-var array<string, array<string, string[]>> 67 * List of PSR-0 prefixes 68 * 69 * Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2'))) 70 * 71 * @var array<string, array<string, list<string>>> 72 72 */ 73 73 private $prefixesPsr0 = array(); 74 74 /** 75 * @var array[] 76 * @psalm-var array<string, string> 75 * @var list<string> 77 76 */ 78 77 private $fallbackDirsPsr0 = array(); … … 82 81 83 82 /** 84 * @var string[] 85 * @psalm-var array<string, string> 83 * @var array<string, string> 86 84 */ 87 85 private $classMap = array(); … … 91 89 92 90 /** 93 * @var bool[] 94 * @psalm-var array<string, bool> 91 * @var array<string, bool> 95 92 */ 96 93 private $missingClasses = array(); 97 94 98 /** @var ?string*/95 /** @var string|null */ 99 96 private $apcuPrefix; 100 97 101 98 /** 102 * @var self[]99 * @var array<string, self> 103 100 */ 104 101 private static $registeredLoaders = array(); 105 102 106 103 /** 107 * @param ?string$vendorDir104 * @param string|null $vendorDir 108 105 */ 109 106 public function __construct($vendorDir = null) … … 114 111 115 112 /** 116 * @return string[]113 * @return array<string, list<string>> 117 114 */ 118 115 public function getPrefixes() … … 126 123 127 124 /** 128 * @return array[] 129 * @psalm-return array<string, array<int, string>> 125 * @return array<string, list<string>> 130 126 */ 131 127 public function getPrefixesPsr4() … … 135 131 136 132 /** 137 * @return array[] 138 * @psalm-return array<string, string> 133 * @return list<string> 139 134 */ 140 135 public function getFallbackDirs() … … 144 139 145 140 /** 146 * @return array[] 147 * @psalm-return array<string, string> 141 * @return list<string> 148 142 */ 149 143 public function getFallbackDirsPsr4() … … 153 147 154 148 /** 155 * @return string[] Array of classname => path 156 * @psalm-return array<string, string> 149 * @return array<string, string> Array of classname => path 157 150 */ 158 151 public function getClassMap() … … 162 155 163 156 /** 164 * @param string[] $classMap Class to filename map 165 * @psalm-param array<string, string> $classMap 157 * @param array<string, string> $classMap Class to filename map 166 158 * 167 159 * @return void … … 180 172 * appending or prepending to the ones previously set for this prefix. 181 173 * 182 * @param string $prefix The prefix183 * @param string[]|string $paths The PSR-0 root directories184 * @param bool $prepend Whether to prepend the directories174 * @param string $prefix The prefix 175 * @param list<string>|string $paths The PSR-0 root directories 176 * @param bool $prepend Whether to prepend the directories 185 177 * 186 178 * @return void … … 188 180 public function add($prefix, $paths, $prepend = false) 189 181 { 182 $paths = (array) $paths; 190 183 if (!$prefix) { 191 184 if ($prepend) { 192 185 $this->fallbackDirsPsr0 = array_merge( 193 (array)$paths,186 $paths, 194 187 $this->fallbackDirsPsr0 195 188 ); … … 197 190 $this->fallbackDirsPsr0 = array_merge( 198 191 $this->fallbackDirsPsr0, 199 (array)$paths192 $paths 200 193 ); 201 194 } … … 206 199 $first = $prefix[0]; 207 200 if (!isset($this->prefixesPsr0[$first][$prefix])) { 208 $this->prefixesPsr0[$first][$prefix] = (array)$paths;201 $this->prefixesPsr0[$first][$prefix] = $paths; 209 202 210 203 return; … … 212 205 if ($prepend) { 213 206 $this->prefixesPsr0[$first][$prefix] = array_merge( 214 (array)$paths,207 $paths, 215 208 $this->prefixesPsr0[$first][$prefix] 216 209 ); … … 218 211 $this->prefixesPsr0[$first][$prefix] = array_merge( 219 212 $this->prefixesPsr0[$first][$prefix], 220 (array)$paths213 $paths 221 214 ); 222 215 } … … 227 220 * appending or prepending to the ones previously set for this namespace. 228 221 * 229 * @param string $prefix The prefix/namespace, with trailing '\\'230 * @param string[]|string $paths The PSR-4 base directories231 * @param bool $prepend Whether to prepend the directories222 * @param string $prefix The prefix/namespace, with trailing '\\' 223 * @param list<string>|string $paths The PSR-4 base directories 224 * @param bool $prepend Whether to prepend the directories 232 225 * 233 226 * @throws \InvalidArgumentException … … 237 230 public function addPsr4($prefix, $paths, $prepend = false) 238 231 { 232 $paths = (array) $paths; 239 233 if (!$prefix) { 240 234 // Register directories for the root namespace. 241 235 if ($prepend) { 242 236 $this->fallbackDirsPsr4 = array_merge( 243 (array)$paths,237 $paths, 244 238 $this->fallbackDirsPsr4 245 239 ); … … 247 241 $this->fallbackDirsPsr4 = array_merge( 248 242 $this->fallbackDirsPsr4, 249 (array)$paths243 $paths 250 244 ); 251 245 } … … 257 251 } 258 252 $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; 259 $this->prefixDirsPsr4[$prefix] = (array)$paths;253 $this->prefixDirsPsr4[$prefix] = $paths; 260 254 } elseif ($prepend) { 261 255 // Prepend directories for an already registered namespace. 262 256 $this->prefixDirsPsr4[$prefix] = array_merge( 263 (array)$paths,257 $paths, 264 258 $this->prefixDirsPsr4[$prefix] 265 259 ); … … 268 262 $this->prefixDirsPsr4[$prefix] = array_merge( 269 263 $this->prefixDirsPsr4[$prefix], 270 (array)$paths264 $paths 271 265 ); 272 266 } … … 277 271 * replacing any others previously set for this prefix. 278 272 * 279 * @param string $prefix The prefix280 * @param string[]|string $paths The PSR-0 base directories273 * @param string $prefix The prefix 274 * @param list<string>|string $paths The PSR-0 base directories 281 275 * 282 276 * @return void … … 295 289 * replacing any others previously set for this namespace. 296 290 * 297 * @param string $prefix The prefix/namespace, with trailing '\\'298 * @param string[]|string $paths The PSR-4 base directories291 * @param string $prefix The prefix/namespace, with trailing '\\' 292 * @param list<string>|string $paths The PSR-4 base directories 299 293 * 300 294 * @throws \InvalidArgumentException … … 430 424 { 431 425 if ($file = $this->findFile($class)) { 432 (self::$includeFile)($file); 426 $includeFile = self::$includeFile; 427 $includeFile($file); 433 428 434 429 return true; … … 481 476 482 477 /** 483 * Returns the currently registered loaders indexed by their corresponding vendor directories.484 * 485 * @return self[]478 * Returns the currently registered loaders keyed by their corresponding vendor directories. 479 * 480 * @return array<string, self> 486 481 */ 487 482 public static function getRegisteredLoaders() … … 561 556 } 562 557 563 private static function initializeIncludeClosure(): void 558 /** 559 * @return void 560 */ 561 private static function initializeIncludeClosure() 564 562 { 565 563 if (self::$includeFile !== null) { … … 575 573 * @return void 576 574 */ 577 self::$includeFile = static function($file) {575 self::$includeFile = \Closure::bind(static function($file) { 578 576 include $file; 579 } ;577 }, null, null); 580 578 } 581 579 } -
smartpay/trunk/vendor/composer/InstalledVersions.php
r2739833 r2933625 99 99 foreach (self::getInstalled() as $installed) { 100 100 if (isset($installed['versions'][$packageName])) { 101 return $includeDevRequirements || empty($installed['versions'][$packageName]['dev_requirement']);101 return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false; 102 102 } 103 103 } … … 120 120 public static function satisfies(VersionParser $parser, $packageName, $constraint) 121 121 { 122 $constraint = $parser->parseConstraints( $constraint);122 $constraint = $parser->parseConstraints((string) $constraint); 123 123 $provided = $parser->parseConstraints(self::getVersionRanges($packageName)); 124 124 … … 329 329 $installed[] = self::$installedByVendor[$vendorDir]; 330 330 } elseif (is_file($vendorDir.'/composer/installed.php')) { 331 $installed[] = self::$installedByVendor[$vendorDir] = require $vendorDir.'/composer/installed.php'; 331 /** @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 */ 332 $required = require $vendorDir.'/composer/installed.php'; 333 $installed[] = self::$installedByVendor[$vendorDir] = $required; 332 334 if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) { 333 335 self::$installed = $installed[count($installed) - 1]; … … 341 343 // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 342 344 if (substr(__DIR__, -8, 1) !== 'C') { 343 self::$installed = require __DIR__ . '/installed.php'; 345 /** @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 */ 346 $required = require __DIR__ . '/installed.php'; 347 self::$installed = $required; 344 348 } else { 345 349 self::$installed = array(); 346 350 } 347 351 } 348 $installed[] = self::$installed; 352 353 if (self::$installed !== array()) { 354 $installed[] = self::$installed; 355 } 349 356 350 357 return $installed; -
smartpay/trunk/vendor/composer/autoload_real.php
r2845050 r2933625 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb155 class ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197 6 6 { 7 7 private static $loader; … … 25 25 require __DIR__ . '/platform_check.php'; 26 26 27 spl_autoload_register(array('ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15', 'loadClassLoader'), true, true);27 spl_autoload_register(array('ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197', 'loadClassLoader'), true, true); 28 28 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 29 spl_autoload_unregister(array('ComposerAutoloaderInit 1d7f05993c4428b947a11e109eefbb15', 'loadClassLoader'));29 spl_autoload_unregister(array('ComposerAutoloaderInitf3f4d46712f95c49e5003fb08b602197', 'loadClassLoader')); 30 30 31 31 require __DIR__ . '/autoload_static.php'; 32 call_user_func(\Composer\Autoload\ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::getInitializer($loader));32 call_user_func(\Composer\Autoload\ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::getInitializer($loader)); 33 33 34 34 $loader->register(true); 35 35 36 $filesToLoad = \Composer\Autoload\ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$files;37 $requireFile = static function ($fileIdentifier, $file) {36 $filesToLoad = \Composer\Autoload\ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$files; 37 $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { 38 38 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { 39 39 $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; … … 41 41 require $file; 42 42 } 43 } ;43 }, null, null); 44 44 foreach ($filesToLoad as $fileIdentifier => $file) { 45 ($requireFile)($fileIdentifier, $file);45 $requireFile($fileIdentifier, $file); 46 46 } 47 47 -
smartpay/trunk/vendor/composer/autoload_static.php
r2845050 r2933625 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit 1d7f05993c4428b947a11e109eefbb157 class ComposerStaticInitf3f4d46712f95c49e5003fb08b602197 8 8 { 9 9 public static $files = array ( … … 111 111 { 112 112 return \Closure::bind(function () use ($loader) { 113 $loader->prefixLengthsPsr4 = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$prefixLengthsPsr4;114 $loader->prefixDirsPsr4 = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$prefixDirsPsr4;115 $loader->classMap = ComposerStaticInit 1d7f05993c4428b947a11e109eefbb15::$classMap;113 $loader->prefixLengthsPsr4 = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$prefixLengthsPsr4; 114 $loader->prefixDirsPsr4 = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$prefixDirsPsr4; 115 $loader->classMap = ComposerStaticInitf3f4d46712f95c49e5003fb08b602197::$classMap; 116 116 117 117 }, null, ClassLoader::class); -
smartpay/trunk/vendor/composer/installed.php
r2845050 r2933625 2 2 'root' => array( 3 3 'name' => 'wp-smartpay/core', 4 'pretty_version' => 'v2.7. 4.2',5 'version' => '2.7. 4.2',6 'reference' => ' fb9868af7fb284ff2294af0f2279632bfe7c7105',4 'pretty_version' => 'v2.7.5', 5 'version' => '2.7.5.0', 6 'reference' => '1cb87ef2823c1de984b2c2100609c505c06fcc2b', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 108 108 ), 109 109 'wp-smartpay/core' => array( 110 'pretty_version' => 'v2.7. 4.2',111 'version' => '2.7. 4.2',112 'reference' => ' fb9868af7fb284ff2294af0f2279632bfe7c7105',110 'pretty_version' => 'v2.7.5', 111 'version' => '2.7.5.0', 112 'reference' => '1cb87ef2823c1de984b2c2100609c505c06fcc2b', 113 113 'type' => 'library', 114 114 'install_path' => __DIR__ . '/../../',
Note: See TracChangeset
for help on using the changeset viewer.