Changeset 3096954
- Timestamp:
- 06/03/2024 08:07:50 PM (22 months ago)
- Location:
- wpappsdev-pcbuilder
- Files:
-
- 130 added
- 13 edited
-
tags/2.1.0 (added)
-
tags/2.1.0/assets (added)
-
tags/2.1.0/assets/css (added)
-
tags/2.1.0/assets/css/wpadpcbu-admin.css (added)
-
tags/2.1.0/assets/css/wpadpcbu-public.css (added)
-
tags/2.1.0/assets/js (added)
-
tags/2.1.0/assets/js/wpadpcbu-admin.js (added)
-
tags/2.1.0/assets/js/wpadpcbu-public.js (added)
-
tags/2.1.0/assets/lib (added)
-
tags/2.1.0/assets/lib/ion.rangeSlider.min.css (added)
-
tags/2.1.0/assets/lib/ion.rangeSlider.min.js (added)
-
tags/2.1.0/assets/lib/waitMe.min.css (added)
-
tags/2.1.0/assets/lib/waitMe.min.js (added)
-
tags/2.1.0/includes (added)
-
tags/2.1.0/includes/Abstracts (added)
-
tags/2.1.0/includes/Abstracts/WPAppsDevShortcode.php (added)
-
tags/2.1.0/includes/Admin (added)
-
tags/2.1.0/includes/Admin.php (added)
-
tags/2.1.0/includes/Admin/Menu.php (added)
-
tags/2.1.0/includes/Admin/Product.php (added)
-
tags/2.1.0/includes/Admin/Settings.php (added)
-
tags/2.1.0/includes/Ajax.php (added)
-
tags/2.1.0/includes/Assets.php (added)
-
tags/2.1.0/includes/Component.php (added)
-
tags/2.1.0/includes/DynamicTaxonomy.php (added)
-
tags/2.1.0/includes/FiltersGroup.php (added)
-
tags/2.1.0/includes/Frontend (added)
-
tags/2.1.0/includes/Frontend.php (added)
-
tags/2.1.0/includes/Frontend/CustomerDashboard.php (added)
-
tags/2.1.0/includes/Helper (added)
-
tags/2.1.0/includes/Helper/BuilderManager.php (added)
-
tags/2.1.0/includes/Helper/SavedConfigurationManager.php (added)
-
tags/2.1.0/includes/Helper/SearchManager.php (added)
-
tags/2.1.0/includes/Installer.php (added)
-
tags/2.1.0/includes/Shortcodes (added)
-
tags/2.1.0/includes/Shortcodes/PcBuilders.php (added)
-
tags/2.1.0/includes/Shortcodes/PcBuildersSearch.php (added)
-
tags/2.1.0/includes/Shortcodes/Shortcodes.php (added)
-
tags/2.1.0/includes/Traits (added)
-
tags/2.1.0/includes/Traits/Singleton.php (added)
-
tags/2.1.0/includes/functions-helper.php (added)
-
tags/2.1.0/languages (added)
-
tags/2.1.0/languages/wpappsdev-pcbuilder.pot (added)
-
tags/2.1.0/readme.txt (added)
-
tags/2.1.0/templates (added)
-
tags/2.1.0/templates/admin (added)
-
tags/2.1.0/templates/admin/admin-notice.php (added)
-
tags/2.1.0/templates/admin/category-add-form.php (added)
-
tags/2.1.0/templates/admin/category-edit-form.php (added)
-
tags/2.1.0/templates/admin/product-metabox.php (added)
-
tags/2.1.0/templates/dashboard (added)
-
tags/2.1.0/templates/dashboard/saved-configurations.php (added)
-
tags/2.1.0/templates/dashboard/view-configuration.php (added)
-
tags/2.1.0/templates/shortcodes (added)
-
tags/2.1.0/templates/shortcodes/pc-builder-product.php (added)
-
tags/2.1.0/templates/shortcodes/pc-builder-search.php (added)
-
tags/2.1.0/templates/shortcodes/pc-builder.php (added)
-
tags/2.1.0/vendor (added)
-
tags/2.1.0/vendor/WPAppsDev (added)
-
tags/2.1.0/vendor/WPAppsDev/WpadCpt.php (added)
-
tags/2.1.0/vendor/WPAppsDev/WpadHelper.php (added)
-
tags/2.1.0/vendor/WPAppsDev/WpadMetaBox.php (added)
-
tags/2.1.0/vendor/WPAppsDev/WpadSettingApi.php (added)
-
tags/2.1.0/vendor/WPAppsDev/WpadTaxonomy.php (added)
-
tags/2.1.0/vendor/WPAppsDev/assets (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/css (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/css/chosen.css (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/css/jqueryui.css (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/css/meta_box.css (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/images (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/images/chosen-sprite.png (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/images/image.png (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/images/sprite.png (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/js (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/js/chosen.js (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/js/nap.js (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/js/scripts.js (added)
-
tags/2.1.0/vendor/WPAppsDev/assets/js/settings.js (added)
-
tags/2.1.0/vendor/WPAppsDev/fields (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/checkbox-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/checkbox-group-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/color-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/date-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/editor-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/email-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/file-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/image-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/image-field1.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/multiimage-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/number-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/post-checkboxes-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/post-drop-sort-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/post-select-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/radio-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/repeatable-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/select-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/slider-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/tax-checkboxes-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/tax-select-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/text-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/textarea-field.php (added)
-
tags/2.1.0/vendor/WPAppsDev/fields/url-field.php (added)
-
tags/2.1.0/vendor/appsero (added)
-
tags/2.1.0/vendor/appsero/client (added)
-
tags/2.1.0/vendor/appsero/client/src (added)
-
tags/2.1.0/vendor/appsero/client/src/Client.php (added)
-
tags/2.1.0/vendor/appsero/client/src/Insights.php (added)
-
tags/2.1.0/vendor/appsero/client/src/License.php (added)
-
tags/2.1.0/vendor/autoload.php (added)
-
tags/2.1.0/vendor/composer (added)
-
tags/2.1.0/vendor/composer/ClassLoader.php (added)
-
tags/2.1.0/vendor/composer/InstalledVersions.php (added)
-
tags/2.1.0/vendor/composer/LICENSE (added)
-
tags/2.1.0/vendor/composer/autoload_classmap.php (added)
-
tags/2.1.0/vendor/composer/autoload_files.php (added)
-
tags/2.1.0/vendor/composer/autoload_namespaces.php (added)
-
tags/2.1.0/vendor/composer/autoload_psr4.php (added)
-
tags/2.1.0/vendor/composer/autoload_real.php (added)
-
tags/2.1.0/vendor/composer/autoload_static.php (added)
-
tags/2.1.0/vendor/composer/installed.json (added)
-
tags/2.1.0/vendor/composer/installed.php (added)
-
tags/2.1.0/vendor/composer/platform_check.php (added)
-
tags/2.1.0/wpappsdev-pcbuilder.php (added)
-
trunk/readme.txt (modified) (3 diffs)
-
trunk/vendor/appsero (added)
-
trunk/vendor/appsero/client (added)
-
trunk/vendor/appsero/client/src (added)
-
trunk/vendor/appsero/client/src/Client.php (added)
-
trunk/vendor/appsero/client/src/Insights.php (added)
-
trunk/vendor/appsero/client/src/License.php (added)
-
trunk/vendor/autoload.php (modified) (1 diff)
-
trunk/vendor/composer/ClassLoader.php (modified) (24 diffs)
-
trunk/vendor/composer/InstalledVersions.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_classmap.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_files.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_namespaces.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_psr4.php (modified) (2 diffs)
-
trunk/vendor/composer/autoload_real.php (modified) (2 diffs)
-
trunk/vendor/composer/autoload_static.php (modified) (2 diffs)
-
trunk/vendor/composer/installed.json (modified) (1 diff)
-
trunk/vendor/composer/installed.php (modified) (1 diff)
-
trunk/vendor/composer/platform_check.php (added)
-
trunk/wpappsdev-pcbuilder.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wpappsdev-pcbuilder/trunk/readme.txt
r3094855 r3096954 2 2 Contributors: saifulananda 3 3 Plugin Name: WooCommerce Custom Product Builder or Configurator - Especially PC Builder Toolkit 4 Tags: PC builder, WooCommerce computer builder, Computer component, product builder, product configurator4 Tags: PC builder, product configurator, WooCommerce computer builder, Computer component, product builder 5 5 Author URI: https://siananda.me/ 6 6 Author: Saiful Islam Ananda 7 Requires at least: 5.0 7 Requires PHP: 7.4 8 Requires at least: 6.0 8 9 Tested up to: 6.5.3 9 Version: 2. 0.010 Stable tag: 2. 0.010 Version: 2.1.0 11 Stable tag: 2.1.0 11 12 License: GPLv2 or later 12 13 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 81 82 [youtube https://www.youtube.com/watch?v=mLDAMtF7_XQ] 82 83 84 ## Privacy Policy 85 86 WooCommerce Custom Product Builder or Configurator – Especially PC Builder Toolkit uses [Appsero](https://appsero.com) SDK to collect some telemetry data upon user's confirmation. This helps us to troubleshoot problems faster & make product improvements. 87 88 Appsero SDK **does not gather any data by default.** The SDK only starts gathering basic telemetry data **when a user allows it via the admin notice**. We collect the data to ensure a great user experience for all our users. 89 90 Integrating Appsero SDK **DOES NOT IMMEDIATELY** start gathering data, **without confirmation from users in any case.** 91 92 Learn more about how [Appsero collects and uses this data](https://appsero.com/privacy-policy/). 93 83 94 == Installation == 84 95 … … 114 125 == Changelog == 115 126 127 = 2.1.0 = 128 * Added: Appsero tracker for plugin analytics. 129 116 130 = 2.0.0 = 117 131 * Updated: Builder page UI. -
wpappsdev-pcbuilder/trunk/vendor/autoload.php
r2607896 r3096954 3 3 // autoload.php @generated by Composer 4 4 5 if (PHP_VERSION_ID < 50600) { 6 if (!headers_sent()) { 7 header('HTTP/1.1 500 Internal Server Error'); 8 } 9 $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; 10 if (!ini_get('display_errors')) { 11 if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') { 12 fwrite(STDERR, $err); 13 } elseif (!headers_sent()) { 14 echo $err; 15 } 16 } 17 trigger_error( 18 $err, 19 E_USER_ERROR 20 ); 21 } 22 5 23 require_once __DIR__ . '/composer/autoload_real.php'; 6 24 -
wpappsdev-pcbuilder/trunk/vendor/composer/ClassLoader.php
r2607896 r3096954 43 43 class ClassLoader 44 44 { 45 /** @var \Closure(string):void */ 46 private static $includeFile; 47 48 /** @var string|null */ 49 private $vendorDir; 50 45 51 // PSR-4 52 /** 53 * @var array<string, array<string, int>> 54 */ 46 55 private $prefixLengthsPsr4 = array(); 56 /** 57 * @var array<string, list<string>> 58 */ 47 59 private $prefixDirsPsr4 = array(); 60 /** 61 * @var list<string> 62 */ 48 63 private $fallbackDirsPsr4 = array(); 49 64 50 65 // PSR-0 66 /** 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 */ 51 73 private $prefixesPsr0 = array(); 74 /** 75 * @var list<string> 76 */ 52 77 private $fallbackDirsPsr0 = array(); 53 78 79 /** @var bool */ 54 80 private $useIncludePath = false; 81 82 /** 83 * @var array<string, string> 84 */ 55 85 private $classMap = array(); 86 87 /** @var bool */ 56 88 private $classMapAuthoritative = false; 89 90 /** 91 * @var array<string, bool> 92 */ 57 93 private $missingClasses = array(); 94 95 /** @var string|null */ 58 96 private $apcuPrefix; 59 97 98 /** 99 * @var array<string, self> 100 */ 101 private static $registeredLoaders = array(); 102 103 /** 104 * @param string|null $vendorDir 105 */ 106 public function __construct($vendorDir = null) 107 { 108 $this->vendorDir = $vendorDir; 109 self::initializeIncludeClosure(); 110 } 111 112 /** 113 * @return array<string, list<string>> 114 */ 60 115 public function getPrefixes() 61 116 { … … 67 122 } 68 123 124 /** 125 * @return array<string, list<string>> 126 */ 69 127 public function getPrefixesPsr4() 70 128 { … … 72 130 } 73 131 132 /** 133 * @return list<string> 134 */ 74 135 public function getFallbackDirs() 75 136 { … … 77 138 } 78 139 140 /** 141 * @return list<string> 142 */ 79 143 public function getFallbackDirsPsr4() 80 144 { … … 82 146 } 83 147 148 /** 149 * @return array<string, string> Array of classname => path 150 */ 84 151 public function getClassMap() 85 152 { … … 88 155 89 156 /** 90 * @param array $classMap Class to filename map 157 * @param array<string, string> $classMap Class to filename map 158 * 159 * @return void 91 160 */ 92 161 public function addClassMap(array $classMap) … … 103 172 * appending or prepending to the ones previously set for this prefix. 104 173 * 105 * @param string $prefix The prefix 106 * @param array|string $paths The PSR-0 root directories 107 * @param bool $prepend Whether to prepend the directories 174 * @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 177 * 178 * @return void 108 179 */ 109 180 public function add($prefix, $paths, $prepend = false) 110 181 { 182 $paths = (array) $paths; 111 183 if (!$prefix) { 112 184 if ($prepend) { 113 185 $this->fallbackDirsPsr0 = array_merge( 114 (array)$paths,186 $paths, 115 187 $this->fallbackDirsPsr0 116 188 ); … … 118 190 $this->fallbackDirsPsr0 = array_merge( 119 191 $this->fallbackDirsPsr0, 120 (array)$paths192 $paths 121 193 ); 122 194 } … … 127 199 $first = $prefix[0]; 128 200 if (!isset($this->prefixesPsr0[$first][$prefix])) { 129 $this->prefixesPsr0[$first][$prefix] = (array)$paths;201 $this->prefixesPsr0[$first][$prefix] = $paths; 130 202 131 203 return; … … 133 205 if ($prepend) { 134 206 $this->prefixesPsr0[$first][$prefix] = array_merge( 135 (array)$paths,207 $paths, 136 208 $this->prefixesPsr0[$first][$prefix] 137 209 ); … … 139 211 $this->prefixesPsr0[$first][$prefix] = array_merge( 140 212 $this->prefixesPsr0[$first][$prefix], 141 (array)$paths213 $paths 142 214 ); 143 215 } … … 148 220 * appending or prepending to the ones previously set for this namespace. 149 221 * 150 * @param string $prefix The prefix/namespace, with trailing '\\'151 * @param array|string $paths The PSR-4 base directories152 * @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 153 225 * 154 226 * @throws \InvalidArgumentException 227 * 228 * @return void 155 229 */ 156 230 public function addPsr4($prefix, $paths, $prepend = false) 157 231 { 232 $paths = (array) $paths; 158 233 if (!$prefix) { 159 234 // Register directories for the root namespace. 160 235 if ($prepend) { 161 236 $this->fallbackDirsPsr4 = array_merge( 162 (array)$paths,237 $paths, 163 238 $this->fallbackDirsPsr4 164 239 ); … … 166 241 $this->fallbackDirsPsr4 = array_merge( 167 242 $this->fallbackDirsPsr4, 168 (array)$paths243 $paths 169 244 ); 170 245 } … … 176 251 } 177 252 $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; 178 $this->prefixDirsPsr4[$prefix] = (array)$paths;253 $this->prefixDirsPsr4[$prefix] = $paths; 179 254 } elseif ($prepend) { 180 255 // Prepend directories for an already registered namespace. 181 256 $this->prefixDirsPsr4[$prefix] = array_merge( 182 (array)$paths,257 $paths, 183 258 $this->prefixDirsPsr4[$prefix] 184 259 ); … … 187 262 $this->prefixDirsPsr4[$prefix] = array_merge( 188 263 $this->prefixDirsPsr4[$prefix], 189 (array)$paths264 $paths 190 265 ); 191 266 } … … 196 271 * replacing any others previously set for this prefix. 197 272 * 198 * @param string $prefix The prefix 199 * @param array|string $paths The PSR-0 base directories 273 * @param string $prefix The prefix 274 * @param list<string>|string $paths The PSR-0 base directories 275 * 276 * @return void 200 277 */ 201 278 public function set($prefix, $paths) … … 212 289 * replacing any others previously set for this namespace. 213 290 * 214 * @param string $prefix The prefix/namespace, with trailing '\\'215 * @param array|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 216 293 * 217 294 * @throws \InvalidArgumentException 295 * 296 * @return void 218 297 */ 219 298 public function setPsr4($prefix, $paths) … … 235 314 * 236 315 * @param bool $useIncludePath 316 * 317 * @return void 237 318 */ 238 319 public function setUseIncludePath($useIncludePath) … … 257 338 * 258 339 * @param bool $classMapAuthoritative 340 * 341 * @return void 259 342 */ 260 343 public function setClassMapAuthoritative($classMapAuthoritative) … … 277 360 * 278 361 * @param string|null $apcuPrefix 362 * 363 * @return void 279 364 */ 280 365 public function setApcuPrefix($apcuPrefix) … … 297 382 * 298 383 * @param bool $prepend Whether to prepend the autoloader or not 384 * 385 * @return void 299 386 */ 300 387 public function register($prepend = false) 301 388 { 302 389 spl_autoload_register(array($this, 'loadClass'), true, $prepend); 390 391 if (null === $this->vendorDir) { 392 return; 393 } 394 395 if ($prepend) { 396 self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; 397 } else { 398 unset(self::$registeredLoaders[$this->vendorDir]); 399 self::$registeredLoaders[$this->vendorDir] = $this; 400 } 303 401 } 304 402 305 403 /** 306 404 * Unregisters this instance as an autoloader. 405 * 406 * @return void 307 407 */ 308 408 public function unregister() 309 409 { 310 410 spl_autoload_unregister(array($this, 'loadClass')); 411 412 if (null !== $this->vendorDir) { 413 unset(self::$registeredLoaders[$this->vendorDir]); 414 } 311 415 } 312 416 … … 315 419 * 316 420 * @param string $class The name of the class 317 * @return bool|null True if loaded, null otherwise421 * @return true|null True if loaded, null otherwise 318 422 */ 319 423 public function loadClass($class) 320 424 { 321 425 if ($file = $this->findFile($class)) { 322 includeFile($file); 426 $includeFile = self::$includeFile; 427 $includeFile($file); 323 428 324 429 return true; 325 430 } 431 432 return null; 326 433 } 327 434 … … 368 475 } 369 476 477 /** 478 * Returns the currently registered loaders keyed by their corresponding vendor directories. 479 * 480 * @return array<string, self> 481 */ 482 public static function getRegisteredLoaders() 483 { 484 return self::$registeredLoaders; 485 } 486 487 /** 488 * @param string $class 489 * @param string $ext 490 * @return string|false 491 */ 370 492 private function findFileWithExtension($class, $ext) 371 493 { … … 433 555 return false; 434 556 } 557 558 /** 559 * @return void 560 */ 561 private static function initializeIncludeClosure() 562 { 563 if (self::$includeFile !== null) { 564 return; 565 } 566 567 /** 568 * Scope isolated include. 569 * 570 * Prevents access to $this/self from included files. 571 * 572 * @param string $file 573 * @return void 574 */ 575 self::$includeFile = \Closure::bind(static function($file) { 576 include $file; 577 }, null, null); 578 } 435 579 } 436 437 /**438 * Scope isolated include.439 *440 * Prevents access to $this/self from included files.441 */442 function includeFile($file)443 {444 include $file;445 } -
wpappsdev-pcbuilder/trunk/vendor/composer/InstalledVersions.php
r2607896 r3096954 1 1 <?php 2 2 3 /* 4 * This file is part of Composer. 5 * 6 * (c) Nils Adermann <naderman@naderman.de> 7 * Jordi Boggiano <j.boggiano@seld.be> 8 * 9 * For the full copyright and license information, please view the LICENSE 10 * file that was distributed with this source code. 11 */ 12 3 13 namespace Composer; 4 14 15 use Composer\Autoload\ClassLoader; 5 16 use Composer\Semver\VersionParser; 6 17 7 8 9 10 11 18 /** 19 * This class is copied in every Composer installed project and available to all 20 * 21 * See also https://getcomposer.org/doc/07-runtime.md#installed-versions 22 * 23 * To require its presence, you can require `composer-runtime-api ^2.0` 24 * 25 * @final 26 */ 12 27 class InstalledVersions 13 28 { 14 private static $installed = array ( 15 'root' => 16 array ( 17 'pretty_version' => 'No version set (parsed as 1.0.0)', 18 'version' => '1.0.0.0', 19 'aliases' => 20 array ( 21 ), 22 'reference' => NULL, 23 'name' => 'siananda/wpappsdev-pcbuilder', 24 ), 25 'versions' => 26 array ( 27 'siananda/wpappsdev-pcbuilder' => 28 array ( 29 'pretty_version' => 'No version set (parsed as 1.0.0)', 30 'version' => '1.0.0.0', 31 'aliases' => 32 array ( 33 ), 34 'reference' => NULL, 35 ), 36 ), 37 ); 38 39 40 41 42 43 44 45 public static function getInstalledPackages() 46 { 47 return array_keys(self::$installed['versions']); 29 /** 30 * @var mixed[]|null 31 * @psalm-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[]}>}|array{}|null 32 */ 33 private static $installed; 34 35 /** 36 * @var bool|null 37 */ 38 private static $canGetVendors; 39 40 /** 41 * @var array[] 42 * @psalm-var array<string, 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[]}>}> 43 */ 44 private static $installedByVendor = array(); 45 46 /** 47 * Returns a list of all package names which are present, either by being installed, replaced or provided 48 * 49 * @return string[] 50 * @psalm-return list<string> 51 */ 52 public static function getInstalledPackages() 53 { 54 $packages = array(); 55 foreach (self::getInstalled() as $installed) { 56 $packages[] = array_keys($installed['versions']); 57 } 58 59 if (1 === \count($packages)) { 60 return $packages[0]; 61 } 62 63 return array_keys(array_flip(\call_user_func_array('array_merge', $packages))); 64 } 65 66 /** 67 * Returns a list of all package names with a specific type e.g. 'library' 68 * 69 * @param string $type 70 * @return string[] 71 * @psalm-return list<string> 72 */ 73 public static function getInstalledPackagesByType($type) 74 { 75 $packagesByType = array(); 76 77 foreach (self::getInstalled() as $installed) { 78 foreach ($installed['versions'] as $name => $package) { 79 if (isset($package['type']) && $package['type'] === $type) { 80 $packagesByType[] = $name; 81 } 82 } 83 } 84 85 return $packagesByType; 86 } 87 88 /** 89 * Checks whether the given package is installed 90 * 91 * This also returns true if the package name is provided or replaced by another package 92 * 93 * @param string $packageName 94 * @param bool $includeDevRequirements 95 * @return bool 96 */ 97 public static function isInstalled($packageName, $includeDevRequirements = true) 98 { 99 foreach (self::getInstalled() as $installed) { 100 if (isset($installed['versions'][$packageName])) { 101 return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false; 102 } 103 } 104 105 return false; 106 } 107 108 /** 109 * Checks whether the given package satisfies a version constraint 110 * 111 * e.g. If you want to know whether version 2.3+ of package foo/bar is installed, you would call: 112 * 113 * Composer\InstalledVersions::satisfies(new VersionParser, 'foo/bar', '^2.3') 114 * 115 * @param VersionParser $parser Install composer/semver to have access to this class and functionality 116 * @param string $packageName 117 * @param string|null $constraint A version constraint to check for, if you pass one you have to make sure composer/semver is required by your package 118 * @return bool 119 */ 120 public static function satisfies(VersionParser $parser, $packageName, $constraint) 121 { 122 $constraint = $parser->parseConstraints((string) $constraint); 123 $provided = $parser->parseConstraints(self::getVersionRanges($packageName)); 124 125 return $provided->matches($constraint); 126 } 127 128 /** 129 * Returns a version constraint representing all the range(s) which are installed for a given package 130 * 131 * It is easier to use this via isInstalled() with the $constraint argument if you need to check 132 * whether a given version of a package is installed, and not just whether it exists 133 * 134 * @param string $packageName 135 * @return string Version constraint usable with composer/semver 136 */ 137 public static function getVersionRanges($packageName) 138 { 139 foreach (self::getInstalled() as $installed) { 140 if (!isset($installed['versions'][$packageName])) { 141 continue; 142 } 143 144 $ranges = array(); 145 if (isset($installed['versions'][$packageName]['pretty_version'])) { 146 $ranges[] = $installed['versions'][$packageName]['pretty_version']; 147 } 148 if (array_key_exists('aliases', $installed['versions'][$packageName])) { 149 $ranges = array_merge($ranges, $installed['versions'][$packageName]['aliases']); 150 } 151 if (array_key_exists('replaced', $installed['versions'][$packageName])) { 152 $ranges = array_merge($ranges, $installed['versions'][$packageName]['replaced']); 153 } 154 if (array_key_exists('provided', $installed['versions'][$packageName])) { 155 $ranges = array_merge($ranges, $installed['versions'][$packageName]['provided']); 156 } 157 158 return implode(' || ', $ranges); 159 } 160 161 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); 162 } 163 164 /** 165 * @param string $packageName 166 * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present 167 */ 168 public static function getVersion($packageName) 169 { 170 foreach (self::getInstalled() as $installed) { 171 if (!isset($installed['versions'][$packageName])) { 172 continue; 173 } 174 175 if (!isset($installed['versions'][$packageName]['version'])) { 176 return null; 177 } 178 179 return $installed['versions'][$packageName]['version']; 180 } 181 182 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); 183 } 184 185 /** 186 * @param string $packageName 187 * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present 188 */ 189 public static function getPrettyVersion($packageName) 190 { 191 foreach (self::getInstalled() as $installed) { 192 if (!isset($installed['versions'][$packageName])) { 193 continue; 194 } 195 196 if (!isset($installed['versions'][$packageName]['pretty_version'])) { 197 return null; 198 } 199 200 return $installed['versions'][$packageName]['pretty_version']; 201 } 202 203 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); 204 } 205 206 /** 207 * @param string $packageName 208 * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as reference 209 */ 210 public static function getReference($packageName) 211 { 212 foreach (self::getInstalled() as $installed) { 213 if (!isset($installed['versions'][$packageName])) { 214 continue; 215 } 216 217 if (!isset($installed['versions'][$packageName]['reference'])) { 218 return null; 219 } 220 221 return $installed['versions'][$packageName]['reference']; 222 } 223 224 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); 225 } 226 227 /** 228 * @param string $packageName 229 * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as install path. Packages of type metapackages also have a null install path. 230 */ 231 public static function getInstallPath($packageName) 232 { 233 foreach (self::getInstalled() as $installed) { 234 if (!isset($installed['versions'][$packageName])) { 235 continue; 236 } 237 238 return isset($installed['versions'][$packageName]['install_path']) ? $installed['versions'][$packageName]['install_path'] : null; 239 } 240 241 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); 242 } 243 244 /** 245 * @return array 246 * @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool} 247 */ 248 public static function getRootPackage() 249 { 250 $installed = self::getInstalled(); 251 252 return $installed[0]['root']; 253 } 254 255 /** 256 * Returns the raw installed.php data for custom implementations 257 * 258 * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect. 259 * @return array[] 260 * @psalm-return 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[]}>} 261 */ 262 public static function getRawData() 263 { 264 @trigger_error('getRawData only returns the first dataset loaded, which may not be what you expect. Use getAllRawData() instead which returns all datasets for all autoloaders present in the process.', E_USER_DEPRECATED); 265 266 if (null === self::$installed) { 267 // only require the installed.php file if this file is loaded from its dumped location, 268 // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 269 if (substr(__DIR__, -8, 1) !== 'C') { 270 self::$installed = include __DIR__ . '/installed.php'; 271 } else { 272 self::$installed = array(); 273 } 274 } 275 276 return self::$installed; 277 } 278 279 /** 280 * Returns the raw data of all installed.php which are currently loaded for custom implementations 281 * 282 * @return array[] 283 * @psalm-return list<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[]}>}> 284 */ 285 public static function getAllRawData() 286 { 287 return self::getInstalled(); 288 } 289 290 /** 291 * Lets you reload the static array from another file 292 * 293 * This is only useful for complex integrations in which a project needs to use 294 * this class but then also needs to execute another project's autoloader in process, 295 * and wants to ensure both projects have access to their version of installed.php. 296 * 297 * A typical case would be PHPUnit, where it would need to make sure it reads all 298 * the data it needs from this class, then call reload() with 299 * `require $CWD/vendor/composer/installed.php` (or similar) as input to make sure 300 * the project in which it runs can then also use this class safely, without 301 * interference between PHPUnit's dependencies and the project's dependencies. 302 * 303 * @param array[] $data A vendor/composer/installed.php data set 304 * @return void 305 * 306 * @psalm-param 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[]}>} $data 307 */ 308 public static function reload($data) 309 { 310 self::$installed = $data; 311 self::$installedByVendor = array(); 312 } 313 314 /** 315 * @return array[] 316 * @psalm-return list<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[]}>}> 317 */ 318 private static function getInstalled() 319 { 320 if (null === self::$canGetVendors) { 321 self::$canGetVendors = method_exists('Composer\Autoload\ClassLoader', 'getRegisteredLoaders'); 322 } 323 324 $installed = array(); 325 326 if (self::$canGetVendors) { 327 foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) { 328 if (isset(self::$installedByVendor[$vendorDir])) { 329 $installed[] = self::$installedByVendor[$vendorDir]; 330 } elseif (is_file($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; 334 if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) { 335 self::$installed = $installed[count($installed) - 1]; 336 } 337 } 338 } 339 } 340 341 if (null === self::$installed) { 342 // only require the installed.php file if this file is loaded from its dumped location, 343 // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 344 if (substr(__DIR__, -8, 1) !== 'C') { 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; 348 } else { 349 self::$installed = array(); 350 } 351 } 352 353 if (self::$installed !== array()) { 354 $installed[] = self::$installed; 355 } 356 357 return $installed; 358 } 48 359 } 49 50 51 52 53 54 55 56 57 58 public static function isInstalled($packageName)59 {60 return isset(self::$installed['versions'][$packageName]);61 }62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 public static function satisfies(VersionParser $parser, $packageName, $constraint)77 {78 $constraint = $parser->parseConstraints($constraint);79 $provided = $parser->parseConstraints(self::getVersionRanges($packageName));80 81 return $provided->matches($constraint);82 }83 84 85 86 87 88 89 90 91 92 93 public static function getVersionRanges($packageName)94 {95 if (!isset(self::$installed['versions'][$packageName])) {96 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');97 }98 99 $ranges = array();100 if (isset(self::$installed['versions'][$packageName]['pretty_version'])) {101 $ranges[] = self::$installed['versions'][$packageName]['pretty_version'];102 }103 if (array_key_exists('aliases', self::$installed['versions'][$packageName])) {104 $ranges = array_merge($ranges, self::$installed['versions'][$packageName]['aliases']);105 }106 if (array_key_exists('replaced', self::$installed['versions'][$packageName])) {107 $ranges = array_merge($ranges, self::$installed['versions'][$packageName]['replaced']);108 }109 if (array_key_exists('provided', self::$installed['versions'][$packageName])) {110 $ranges = array_merge($ranges, self::$installed['versions'][$packageName]['provided']);111 }112 113 return implode(' || ', $ranges);114 }115 116 117 118 119 120 public static function getVersion($packageName)121 {122 if (!isset(self::$installed['versions'][$packageName])) {123 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');124 }125 126 if (!isset(self::$installed['versions'][$packageName]['version'])) {127 return null;128 }129 130 return self::$installed['versions'][$packageName]['version'];131 }132 133 134 135 136 137 public static function getPrettyVersion($packageName)138 {139 if (!isset(self::$installed['versions'][$packageName])) {140 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');141 }142 143 if (!isset(self::$installed['versions'][$packageName]['pretty_version'])) {144 return null;145 }146 147 return self::$installed['versions'][$packageName]['pretty_version'];148 }149 150 151 152 153 154 public static function getReference($packageName)155 {156 if (!isset(self::$installed['versions'][$packageName])) {157 throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');158 }159 160 if (!isset(self::$installed['versions'][$packageName]['reference'])) {161 return null;162 }163 164 return self::$installed['versions'][$packageName]['reference'];165 }166 167 168 169 170 171 public static function getRootPackage()172 {173 return self::$installed['root'];174 }175 176 177 178 179 180 181 182 public static function getRawData()183 {184 return self::$installed;185 }186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 public static function reload($data)206 {207 self::$installed = $data;208 }209 } -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_classmap.php
r2607896 r3096954 3 3 // autoload_classmap.php @generated by Composer 4 4 5 $vendorDir = dirname( dirname(__FILE__));5 $vendorDir = dirname(__DIR__); 6 6 $baseDir = dirname($vendorDir); 7 7 -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_files.php
r2607896 r3096954 3 3 // autoload_files.php @generated by Composer 4 4 5 $vendorDir = dirname( dirname(__FILE__));5 $vendorDir = dirname(__DIR__); 6 6 $baseDir = dirname($vendorDir); 7 7 -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_namespaces.php
r2607896 r3096954 3 3 // autoload_namespaces.php @generated by Composer 4 4 5 $vendorDir = dirname( dirname(__FILE__));5 $vendorDir = dirname(__DIR__); 6 6 $baseDir = dirname($vendorDir); 7 7 -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_psr4.php
r2607896 r3096954 3 3 // autoload_psr4.php @generated by Composer 4 4 5 $vendorDir = dirname( dirname(__FILE__));5 $vendorDir = dirname(__DIR__); 6 6 $baseDir = dirname($vendorDir); 7 7 … … 9 9 'WPAppsDev\\PCBU\\' => array($baseDir . '/includes'), 10 10 'WPAppsDev\\' => array($vendorDir . '/WPAppsDev'), 11 'Appsero\\' => array($vendorDir . '/appsero/client/src'), 11 12 ); -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_real.php
r2607896 r3096954 23 23 } 24 24 25 require __DIR__ . '/platform_check.php'; 26 25 27 spl_autoload_register(array('ComposerAutoloaderInit5645c28ddb44a6c147bae9a9a469ff33', 'loadClassLoader'), true, true); 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader( );28 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 27 29 spl_autoload_unregister(array('ComposerAutoloaderInit5645c28ddb44a6c147bae9a9a469ff33', 'loadClassLoader')); 28 30 29 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); 30 if ($useStaticLoader) { 31 require __DIR__ . '/autoload_static.php'; 32 33 call_user_func(\Composer\Autoload\ComposerStaticInit5645c28ddb44a6c147bae9a9a469ff33::getInitializer($loader)); 34 } else { 35 $map = require __DIR__ . '/autoload_namespaces.php'; 36 foreach ($map as $namespace => $path) { 37 $loader->set($namespace, $path); 38 } 39 40 $map = require __DIR__ . '/autoload_psr4.php'; 41 foreach ($map as $namespace => $path) { 42 $loader->setPsr4($namespace, $path); 43 } 44 45 $classMap = require __DIR__ . '/autoload_classmap.php'; 46 if ($classMap) { 47 $loader->addClassMap($classMap); 48 } 49 } 31 require __DIR__ . '/autoload_static.php'; 32 call_user_func(\Composer\Autoload\ComposerStaticInit5645c28ddb44a6c147bae9a9a469ff33::getInitializer($loader)); 50 33 51 34 $loader->register(true); 52 35 53 if ($useStaticLoader) { 54 $includeFiles = Composer\Autoload\ComposerStaticInit5645c28ddb44a6c147bae9a9a469ff33::$files; 55 } else { 56 $includeFiles = require __DIR__ . '/autoload_files.php'; 57 } 58 foreach ($includeFiles as $fileIdentifier => $file) { 59 composerRequire5645c28ddb44a6c147bae9a9a469ff33($fileIdentifier, $file); 36 $filesToLoad = \Composer\Autoload\ComposerStaticInit5645c28ddb44a6c147bae9a9a469ff33::$files; 37 $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { 38 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { 39 $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; 40 41 require $file; 42 } 43 }, null, null); 44 foreach ($filesToLoad as $fileIdentifier => $file) { 45 $requireFile($fileIdentifier, $file); 60 46 } 61 47 … … 63 49 } 64 50 } 65 66 function composerRequire5645c28ddb44a6c147bae9a9a469ff33($fileIdentifier, $file)67 {68 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {69 require $file;70 71 $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;72 }73 } -
wpappsdev-pcbuilder/trunk/vendor/composer/autoload_static.php
r2607896 r3096954 17 17 'WPAppsDev\\' => 10, 18 18 ), 19 'A' => 20 array ( 21 'Appsero\\' => 8, 22 ), 19 23 ); 20 24 … … 27 31 array ( 28 32 0 => __DIR__ . '/..' . '/WPAppsDev', 33 ), 34 'Appsero\\' => 35 array ( 36 0 => __DIR__ . '/..' . '/appsero/client/src', 29 37 ), 30 38 ); -
wpappsdev-pcbuilder/trunk/vendor/composer/installed.json
r2607896 r3096954 1 1 { 2 "packages": [], 3 "dev": true 2 "packages": [ 3 { 4 "name": "appsero/client", 5 "version": "dev-develop", 6 "version_normalized": "dev-develop", 7 "source": { 8 "type": "git", 9 "url": "https://github.com/Appsero/client.git", 10 "reference": "a8e02e8a5a862671f04ff00a456e2711d807a598" 11 }, 12 "dist": { 13 "type": "zip", 14 "url": "https://api.github.com/repos/Appsero/client/zipball/a8e02e8a5a862671f04ff00a456e2711d807a598", 15 "reference": "a8e02e8a5a862671f04ff00a456e2711d807a598", 16 "shasum": "" 17 }, 18 "require": { 19 "php": ">=5.6" 20 }, 21 "require-dev": { 22 "dealerdirect/phpcodesniffer-composer-installer": "^0.7.2", 23 "phpcompatibility/phpcompatibility-wp": "dev-master", 24 "phpunit/phpunit": "^8.5.31", 25 "squizlabs/php_codesniffer": "^3.7", 26 "tareq1988/wp-php-cs-fixer": "dev-master", 27 "wp-coding-standards/wpcs": "dev-develop" 28 }, 29 "time": "2024-01-30T08:15:23+00:00", 30 "default-branch": true, 31 "type": "library", 32 "installation-source": "dist", 33 "autoload": { 34 "psr-4": { 35 "Appsero\\": "src/" 36 } 37 }, 38 "notification-url": "https://packagist.org/downloads/", 39 "license": [ 40 "MIT" 41 ], 42 "authors": [ 43 { 44 "name": "Tareq Hasan", 45 "email": "tareq@appsero.com" 46 } 47 ], 48 "description": "Appsero Client", 49 "keywords": [ 50 "analytics", 51 "plugin", 52 "theme", 53 "wordpress" 54 ], 55 "support": { 56 "issues": "https://github.com/Appsero/client/issues", 57 "source": "https://github.com/Appsero/client/tree/develop" 58 }, 59 "install-path": "../appsero/client" 60 } 61 ], 62 "dev": true, 63 "dev-package-names": [] 4 64 } -
wpappsdev-pcbuilder/trunk/vendor/composer/installed.php
r2607896 r3096954 1 <?php return array ( 2 'root' => 3 array ( 4 'pretty_version' => 'No version set (parsed as 1.0.0)', 5 'version' => '1.0.0.0', 6 'aliases' => 7 array ( 1 <?php return array( 2 'root' => array( 3 'name' => 'siananda/wpappsdev-pcbuilder', 4 'pretty_version' => 'dev-master', 5 'version' => 'dev-master', 6 'reference' => 'c91594424ac7782a84aebe79a9216ba38e16aeeb', 7 'type' => 'wordpress-plugin', 8 'install_path' => __DIR__ . '/../../', 9 'aliases' => array(), 10 'dev' => true, 8 11 ), 9 'reference' => NULL, 10 'name' => 'siananda/wpappsdev-pcbuilder', 11 ), 12 'versions' => 13 array ( 14 'siananda/wpappsdev-pcbuilder' => 15 array ( 16 'pretty_version' => 'No version set (parsed as 1.0.0)', 17 'version' => '1.0.0.0', 18 'aliases' => 19 array ( 20 ), 21 'reference' => NULL, 12 'versions' => array( 13 'appsero/client' => array( 14 'pretty_version' => 'dev-develop', 15 'version' => 'dev-develop', 16 'reference' => 'a8e02e8a5a862671f04ff00a456e2711d807a598', 17 'type' => 'library', 18 'install_path' => __DIR__ . '/../appsero/client', 19 'aliases' => array( 20 0 => '9999999-dev', 21 ), 22 'dev_requirement' => false, 23 ), 24 'siananda/wpappsdev-pcbuilder' => array( 25 'pretty_version' => 'dev-master', 26 'version' => 'dev-master', 27 'reference' => 'c91594424ac7782a84aebe79a9216ba38e16aeeb', 28 'type' => 'wordpress-plugin', 29 'install_path' => __DIR__ . '/../../', 30 'aliases' => array(), 31 'dev_requirement' => false, 32 ), 22 33 ), 23 ),24 34 ); -
wpappsdev-pcbuilder/trunk/wpappsdev-pcbuilder.php
r3094849 r3096954 3 3 * Plugin Name: WooCommerce Custom Product Builder or Configurator - Especially PC Builder Toolkit 4 4 * Description: Complete personal computer (PC) components selling solution toolkit for WooCommerce. This increases sales by Creating a product configuration for your online store. Assist in the assembly of a finished product from individual components. 5 * Version: 2. 0.05 * Version: 2.1.0 6 6 * Author: Saiful Islam Ananda 7 7 * Author URI: http://siananda.me/ … … 10 10 * Text Domain: wpappsdev-pcbuilder 11 11 * Domain Path: /languages 12 * Requires at least: 6.0 13 * Requires PHP: 7.4 12 14 * WC tested up to: 8.9 13 15 */ … … 33 35 * @var string 34 36 */ 35 public $version = '2. 0.0';37 public $version = '2.1.0'; 36 38 37 39 /** … … 65 67 register_activation_hook( __FILE__, [ $this, 'activate' ] ); 66 68 register_deactivation_hook( __FILE__, [ $this, 'deactivate' ] ); 69 70 $this->init_appsero_tracker(); 67 71 68 72 add_action( 'plugins_loaded', [ $this, 'init_plugin' ] ); … … 300 304 */ 301 305 public static function check_required_plugin() { 302 if ( in_array( 'woocommerce/woocommerce.php', (array) get_option( 'active_plugins', [] ) ) ) { 303 return true; 304 } 305 306 return false; 306 $required_install = false; 307 308 if ( ! function_exists( 'is_plugin_active_for_network' ) || ! function_exists( 'is_plugin_active' ) ) { 309 require_once ABSPATH . '/wp-admin/includes/plugin.php'; 310 } 311 312 if ( is_plugin_active( 'woocommerce/woocommerce.php' ) ) { 313 $required_install = true; 314 } 315 316 if ( is_multisite() ) { 317 if ( is_plugin_active_for_network( 'woocommerce/woocommerce.php' ) ) { 318 $required_install = true; 319 } 320 } 321 322 return $required_install; 307 323 } 308 324 … … 311 327 * 312 328 * @return void 313 *314 329 */ 315 330 public function required_plugin_notice() { … … 317 332 318 333 include_once WPADPCBU_DIR . 'templates/admin/admin-notice.php'; 334 } 335 336 /** 337 * Initialize the plugin tracker. 338 * 339 * @since 2.1.0 340 * 341 * @return void 342 */ 343 public function init_appsero_tracker() { 344 if ( ! class_exists( 'Appsero\Client' ) ) { 345 require_once __DIR__ . '/vendor/appsero/src/Client.php'; 346 } 347 348 $client = new Appsero\Client( 'faa1d4fa-159c-48f1-8cfd-a4da805e9931', 'WooCommerce Custom Product Builder or Configurator – Especially PC Builder Toolkit', WPADPCBU ); 349 350 // Active insights 351 $client->insights()->init(); 319 352 } 320 353
Note: See TracChangeset
for help on using the changeset viewer.