Plugin Directory

Changeset 2666476


Ignore:
Timestamp:
01/26/2022 10:46:56 PM (4 years ago)
Author:
wundermatics
Message:

version: 1.3.1

Location:
calculated-fields-for-acf/trunk
Files:
3 added
2 deleted
8 edited

Legend:

Unmodified
Added
Removed
  • calculated-fields-for-acf/trunk/calculated-fields-for-acf.php

    r2419071 r2666476  
    99 * Plugin URI:        https://www.wundermatics.com/product/calculated-fields-for-acf
    1010 * Description:       Simple field math for Advanced Custom Fields
    11  * Version:           1.3
     11 * Version:           1.3.1
    1212 * Author:            Wundermatics
    1313 * Author URI:        https://wundermatics.com
     
    1818 */
    1919
    20 $calculated_fields_for_acf_version = '1.3';
     20$calculated_fields_for_acf_version = '1.3.1';
    2121$dependencies = [];
    2222
  • calculated-fields-for-acf/trunk/languages/calculated-fields-for-acf.pot

    r2419071 r2666476  
    1 # Copyright (C) 2020 Calculated fields for ACF
     1# Copyright (C) 2022 Calculated fields for ACF
    22# This file is distributed under the same license as the Calculated fields for ACF package.
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: Calculated fields for ACF 1.3\n"
     5"Project-Id-Version: Calculated fields for ACF 1.3.1\n"
    66"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/calculated-fields-"
    77"for-acf\n"
    8 "POT-Creation-Date: 2020-11-15 19:49:07+00:00\n"
     8"POT-Creation-Date: 2022-01-26 22:44:20+00:00\n"
    99"MIME-Version: 1.0\n"
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "PO-Revision-Date: 2020-MO-DA HO:MI+ZONE\n"
     12"PO-Revision-Date: 2022-MO-DA HO:MI+ZONE\n"
    1313"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
    1414"Language-Team: LANGUAGE <LL@li.org>\n"
  • calculated-fields-for-acf/trunk/readme.txt

    r2419071 r2666476  
    33Tags: acf, admin
    44Requires at least: 4.7
    5 Tested up to: 5.5
     5Tested up to: 5.9
    66Requires PHP: 7.0
    7 Stable tag: 1.3
     7Stable tag: 1.3.1
    88License: GPLv2 or later
    99
  • calculated-fields-for-acf/trunk/src/Stack.php

    r2206588 r2666476  
    11<?php
     2
    23namespace CalculatedFields;
    34
     
    3637{
    3738    /**
    38      * @var array
     39     * @var array<int, mixed>
    3940     */
    4041    public $stack = array();
     42
    4143    /**
    4244     * @var int
     
    4547
    4648    /**
    47      * @param $val
     49     * @param mixed $val
     50     *
     51     * @return void
    4852     */
    4953    public function push($val)
     
    6771    /**
    6872     * @param int $n
     73     *
    6974     * @return mixed|null
    7075     */
  • calculated-fields-for-acf/trunk/vendor/autoload.php

    r2419071 r2666476  
    55require_once __DIR__ . '/composer/autoload_real.php';
    66
    7 return ComposerAutoloaderInit32e9c4d98cb5adff4785af403584ceb0::getLoader();
     7return ComposerAutoloaderInit1090df91b4a4e619de98a1908a7edd20::getLoader();
  • calculated-fields-for-acf/trunk/vendor/composer/ClassLoader.php

    r2419071 r2666476  
    4343class ClassLoader
    4444{
     45    /** @var ?string */
     46    private $vendorDir;
     47
    4548    // PSR-4
     49    /**
     50     * @var array[]
     51     * @psalm-var array<string, array<string, int>>
     52     */
    4653    private $prefixLengthsPsr4 = array();
     54    /**
     55     * @var array[]
     56     * @psalm-var array<string, array<int, string>>
     57     */
    4758    private $prefixDirsPsr4 = array();
     59    /**
     60     * @var array[]
     61     * @psalm-var array<string, string>
     62     */
    4863    private $fallbackDirsPsr4 = array();
    4964
    5065    // PSR-0
     66    /**
     67     * @var array[]
     68     * @psalm-var array<string, array<string, string[]>>
     69     */
    5170    private $prefixesPsr0 = array();
     71    /**
     72     * @var array[]
     73     * @psalm-var array<string, string>
     74     */
    5275    private $fallbackDirsPsr0 = array();
    5376
     77    /** @var bool */
    5478    private $useIncludePath = false;
     79
     80    /**
     81     * @var string[]
     82     * @psalm-var array<string, string>
     83     */
    5584    private $classMap = array();
     85
     86    /** @var bool */
    5687    private $classMapAuthoritative = false;
     88
     89    /**
     90     * @var bool[]
     91     * @psalm-var array<string, bool>
     92     */
    5793    private $missingClasses = array();
     94
     95    /** @var ?string */
    5896    private $apcuPrefix;
    5997
     98    /**
     99     * @var self[]
     100     */
     101    private static $registeredLoaders = array();
     102
     103    /**
     104     * @param ?string $vendorDir
     105     */
     106    public function __construct($vendorDir = null)
     107    {
     108        $this->vendorDir = $vendorDir;
     109    }
     110
     111    /**
     112     * @return string[]
     113     */
    60114    public function getPrefixes()
    61115    {
     
    67121    }
    68122
     123    /**
     124     * @return array[]
     125     * @psalm-return array<string, array<int, string>>
     126     */
    69127    public function getPrefixesPsr4()
    70128    {
     
    72130    }
    73131
     132    /**
     133     * @return array[]
     134     * @psalm-return array<string, string>
     135     */
    74136    public function getFallbackDirs()
    75137    {
     
    77139    }
    78140
     141    /**
     142     * @return array[]
     143     * @psalm-return array<string, string>
     144     */
    79145    public function getFallbackDirsPsr4()
    80146    {
     
    82148    }
    83149
     150    /**
     151     * @return string[] Array of classname => path
     152     * @psalm-return array<string, string>
     153     */
    84154    public function getClassMap()
    85155    {
     
    88158
    89159    /**
    90      * @param array $classMap Class to filename map
     160     * @param string[] $classMap Class to filename map
     161     * @psalm-param array<string, string> $classMap
     162     *
     163     * @return void
    91164     */
    92165    public function addClassMap(array $classMap)
     
    103176     * appending or prepending to the ones previously set for this prefix.
    104177     *
    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
     178     * @param string          $prefix  The prefix
     179     * @param string[]|string $paths   The PSR-0 root directories
     180     * @param bool            $prepend Whether to prepend the directories
     181     *
     182     * @return void
    108183     */
    109184    public function add($prefix, $paths, $prepend = false)
     
    148223     * appending or prepending to the ones previously set for this namespace.
    149224     *
    150      * @param string       $prefix  The prefix/namespace, with trailing '\\'
    151      * @param array|string $paths   The PSR-4 base directories
    152      * @param bool         $prepend Whether to prepend the directories
     225     * @param string          $prefix  The prefix/namespace, with trailing '\\'
     226     * @param string[]|string $paths   The PSR-4 base directories
     227     * @param bool            $prepend Whether to prepend the directories
    153228     *
    154229     * @throws \InvalidArgumentException
     230     *
     231     * @return void
    155232     */
    156233    public function addPsr4($prefix, $paths, $prepend = false)
     
    196273     * replacing any others previously set for this prefix.
    197274     *
    198      * @param string       $prefix The prefix
    199      * @param array|string $paths  The PSR-0 base directories
     275     * @param string          $prefix The prefix
     276     * @param string[]|string $paths  The PSR-0 base directories
     277     *
     278     * @return void
    200279     */
    201280    public function set($prefix, $paths)
     
    212291     * replacing any others previously set for this namespace.
    213292     *
    214      * @param string       $prefix The prefix/namespace, with trailing '\\'
    215      * @param array|string $paths  The PSR-4 base directories
     293     * @param string          $prefix The prefix/namespace, with trailing '\\'
     294     * @param string[]|string $paths  The PSR-4 base directories
    216295     *
    217296     * @throws \InvalidArgumentException
     297     *
     298     * @return void
    218299     */
    219300    public function setPsr4($prefix, $paths)
     
    235316     *
    236317     * @param bool $useIncludePath
     318     *
     319     * @return void
    237320     */
    238321    public function setUseIncludePath($useIncludePath)
     
    257340     *
    258341     * @param bool $classMapAuthoritative
     342     *
     343     * @return void
    259344     */
    260345    public function setClassMapAuthoritative($classMapAuthoritative)
     
    277362     *
    278363     * @param string|null $apcuPrefix
     364     *
     365     * @return void
    279366     */
    280367    public function setApcuPrefix($apcuPrefix)
     
    297384     *
    298385     * @param bool $prepend Whether to prepend the autoloader or not
     386     *
     387     * @return void
    299388     */
    300389    public function register($prepend = false)
    301390    {
    302391        spl_autoload_register(array($this, 'loadClass'), true, $prepend);
     392
     393        if (null === $this->vendorDir) {
     394            return;
     395        }
     396
     397        if ($prepend) {
     398            self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
     399        } else {
     400            unset(self::$registeredLoaders[$this->vendorDir]);
     401            self::$registeredLoaders[$this->vendorDir] = $this;
     402        }
    303403    }
    304404
    305405    /**
    306406     * Unregisters this instance as an autoloader.
     407     *
     408     * @return void
    307409     */
    308410    public function unregister()
    309411    {
    310412        spl_autoload_unregister(array($this, 'loadClass'));
     413
     414        if (null !== $this->vendorDir) {
     415            unset(self::$registeredLoaders[$this->vendorDir]);
     416        }
    311417    }
    312418
     
    315421     *
    316422     * @param  string    $class The name of the class
    317      * @return bool|null True if loaded, null otherwise
     423     * @return true|null True if loaded, null otherwise
    318424     */
    319425    public function loadClass($class)
     
    324430            return true;
    325431        }
     432
     433        return null;
    326434    }
    327435
     
    368476    }
    369477
     478    /**
     479     * Returns the currently registered loaders indexed by their corresponding vendor directories.
     480     *
     481     * @return self[]
     482     */
     483    public static function getRegisteredLoaders()
     484    {
     485        return self::$registeredLoaders;
     486    }
     487
     488    /**
     489     * @param  string       $class
     490     * @param  string       $ext
     491     * @return string|false
     492     */
    370493    private function findFileWithExtension($class, $ext)
    371494    {
     
    439562 *
    440563 * Prevents access to $this/self from included files.
     564 *
     565 * @param  string $file
     566 * @return void
     567 * @private
    441568 */
    442569function includeFile($file)
  • calculated-fields-for-acf/trunk/vendor/composer/autoload_real.php

    r2419071 r2666476  
    33// autoload_real.php @generated by Composer
    44
    5 class ComposerAutoloaderInit32e9c4d98cb5adff4785af403584ceb0
     5class ComposerAutoloaderInit1090df91b4a4e619de98a1908a7edd20
    66{
    77    private static $loader;
     
    2323        }
    2424
    25         spl_autoload_register(array('ComposerAutoloaderInit32e9c4d98cb5adff4785af403584ceb0', 'loadClassLoader'), true, true);
    26         self::$loader = $loader = new \Composer\Autoload\ClassLoader();
    27         spl_autoload_unregister(array('ComposerAutoloaderInit32e9c4d98cb5adff4785af403584ceb0', 'loadClassLoader'));
     25        spl_autoload_register(array('ComposerAutoloaderInit1090df91b4a4e619de98a1908a7edd20', 'loadClassLoader'), true, true);
     26        self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
     27        spl_autoload_unregister(array('ComposerAutoloaderInit1090df91b4a4e619de98a1908a7edd20', 'loadClassLoader'));
    2828
    2929        $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
     
    3131            require __DIR__ . '/autoload_static.php';
    3232
    33             call_user_func(\Composer\Autoload\ComposerStaticInit32e9c4d98cb5adff4785af403584ceb0::getInitializer($loader));
     33            call_user_func(\Composer\Autoload\ComposerStaticInit1090df91b4a4e619de98a1908a7edd20::getInitializer($loader));
    3434        } else {
    3535            $map = require __DIR__ . '/autoload_namespaces.php';
  • calculated-fields-for-acf/trunk/vendor/composer/autoload_static.php

    r2419071 r2666476  
    55namespace Composer\Autoload;
    66
    7 class ComposerStaticInit32e9c4d98cb5adff4785af403584ceb0
     7class ComposerStaticInit1090df91b4a4e619de98a1908a7edd20
    88{
    99    public static $prefixLengthsPsr4 = array (
     
    2828    {
    2929        return \Closure::bind(function () use ($loader) {
    30             $loader->prefixLengthsPsr4 = ComposerStaticInit32e9c4d98cb5adff4785af403584ceb0::$prefixLengthsPsr4;
    31             $loader->prefixDirsPsr4 = ComposerStaticInit32e9c4d98cb5adff4785af403584ceb0::$prefixDirsPsr4;
    32             $loader->classMap = ComposerStaticInit32e9c4d98cb5adff4785af403584ceb0::$classMap;
     30            $loader->prefixLengthsPsr4 = ComposerStaticInit1090df91b4a4e619de98a1908a7edd20::$prefixLengthsPsr4;
     31            $loader->prefixDirsPsr4 = ComposerStaticInit1090df91b4a4e619de98a1908a7edd20::$prefixDirsPsr4;
     32            $loader->classMap = ComposerStaticInit1090df91b4a4e619de98a1908a7edd20::$classMap;
    3333
    3434        }, null, ClassLoader::class);
Note: See TracChangeset for help on using the changeset viewer.