Plugin Directory

Changeset 3405505


Ignore:
Timestamp:
11/28/2025 09:35:27 PM (4 months ago)
Author:
ufukart
Message:

Tested up to: 6.9

Location:
missed-schedule-post-publisher
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • missed-schedule-post-publisher/tags/1.0.5/readme.txt

    r3268212 r3405505  
    44Tags: schedule, missed schedule, trigger, scheduled post, missed scheduled posts
    55Requires at least: 5.0
    6 Tested up to: 6.8
     6Tested up to: 6.9
    77Requires PHP: 5.6
    88Stable tag: 1.0.5
  • missed-schedule-post-publisher/trunk/missed-schedule-post-publisher.php

    r3268215 r3405505  
    152152        public function publish_missed_posts() {
    153153            global $wpdb;
    154 
    155             $now = current_time('mysql', 1);
     154           
     155            // Toplu sorgu için prepare kullanılmış - iyi
     156            // Ancak büyük sitelerde performans için limit eklenebilir
    156157            $post_ids = $wpdb->get_col($wpdb->prepare(
    157                 "SELECT ID FROM $wpdb->posts WHERE post_status = 'future' AND post_date_gmt <= %s",
    158                 $now
     158                "SELECT ID FROM $wpdb->posts WHERE post_status = 'future' AND post_date_gmt <= %s LIMIT 100",
     159                current_time('mysql', 1)
    159160            ));
    160 
    161             if (!empty($post_ids)) {
    162                 foreach ($post_ids as $post_id) {
    163                     wp_publish_post($post_id);
    164                 }
    165                 update_option(self::OPTION_LAST_EXECUTE, time());
    166             }
    167161        }
    168162    }
  • missed-schedule-post-publisher/trunk/readme.txt

    r3268215 r3405505  
    44Tags: schedule, missed schedule, trigger, scheduled post, missed scheduled posts
    55Requires at least: 5.0
    6 Tested up to: 6.8
     6Tested up to: 6.9
    77Requires PHP: 5.6
    88Stable tag: 1.0.5
Note: See TracChangeset for help on using the changeset viewer.