WS_OK_7.4.33 HEX
HEX
Server: nginx/1.21.4
System: Linux v12674 6.8.0-85-generic #85-Ubuntu SMP PREEMPT_DYNAMIC Thu Sep 18 15:26:59 UTC 2025 x86_64
User: endtheignorance (1014)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source
Upload Files
File: /storage/v12674/lcalosangeles/public_html/wp-content/plugins/autoupdater/lib/Upgrader/Theme.php
<?php
defined('AUTOUPDATER_LIB') or die;

class AutoUpdater_Upgrader_Theme extends Theme_Upgrader
{
    /**
     * Unpack a compressed package file.
     *
     * @since  2.8.0
     * @access public
     *
     * @global WP_Filesystem_Base $wp_filesystem  Subclass
     *
     * @param string              $package        Full path to the package file.
     * @param bool                $delete_package Optional. Whether to delete the package file after attempting
     *                                            to unpack it. Default true.
     *
     * @return string|WP_Error The path to the unpacked contents, or a WP_Error on failure.
     */
    public function unpack_package($package, $delete_package = true)
    {
        global $wp_filesystem;

        // Do not unpack if it is already done
        if ($wp_filesystem->is_dir($package)) {
            return $package;
        }

        return parent::unpack_package($package, $delete_package);
    }

    /**
     * Run an upgrade/install.
     *
     * Attempts to download the package (if it is not a local file), unpack it, and
     * install it in the destination folder.
     *
     * @since  2.8.0
     * @access public
     *
     * @param array $options                     {
     *                                           Array or string of arguments for upgrading/installing a package.
     *
     * @type string $package                     The full path or URI of the package to install.
     *                                               Default empty.
     * @type string $destination                 The full path to the destination folder.
     *                                               Default empty.
     * @type bool   $clear_destination           Whether to delete any files already in the
     *                                               destination folder. Default false.
     * @type bool   $clear_working               Whether to delete the files form the working
     *                                               directory after copying to the destination.
     *                                               Default false.
     * @type bool   $abort_if_destination_exists Whether to abort the installation if the destination
     *                                               folder already exists. When true, `$clear_destination`
     *                                               should be false. Default true.
     * @type bool   $is_multi                    Whether this run is one of multiple upgrade/install
     *                                               actions being performed in bulk. When true, the skin
     *                                               WP_Upgrader::header() and WP_Upgrader::footer()
     *                                               aren't called. Default false.
     * @type array  $hook_extra                  Extra arguments to pass to the filter hooks called by
     *                                               WP_Upgrader::run().
     * }
     * @return array|false|WP_error The result from self::install_package() on success, otherwise a WP_Error,
     *                              or false if unable to connect to the filesystem.
     */
    public function run($options)
    {
        /** @since 3.6.0 */
        $options['abort_if_destination_exists'] = false;
        $options['clear_destination'] = true;

        return parent::run($options);
    }
}