crash_ts() public method

* FeedWordPress::update ()
public crash_ts ( $default = NULL )
function fwp_dashboard_update_if_requested($object)
{
    global $wpdb;
    $update_set = $object->updates_requested();
    if (count($update_set) > 0) {
        shuffle($update_set);
        // randomize order for load balancing purposes...
        $feedwordpress = new FeedWordPress();
        add_action('feedwordpress_check_feed', 'update_feeds_mention');
        add_action('feedwordpress_check_feed_complete', 'update_feeds_finish', 10, 3);
        $crash_ts = $feedwordpress->crash_ts();
        echo "<div class=\"update-results\">\n";
        echo "<ul>\n";
        $tdelta = NULL;
        foreach ($update_set as $uri) {
            if (!is_null($crash_ts) and time() > $crash_ts) {
                echo "<li><p><strong>Further updates postponed:</strong> update time limit of " . $crash_dt . " second" . ($crash_dt == 1 ? "" : "s") . " exceeded.</p></li>";
                break;
            }
            if ($uri == '*') {
                $uri = NULL;
            }
            $delta = $feedwordpress->update($uri, $crash_ts);
            if (!is_null($delta)) {
                if (is_null($tdelta)) {
                    $tdelta = $delta;
                } else {
                    $tdelta['new'] += $delta['new'];
                    $tdelta['updated'] += $delta['updated'];
                }
            } else {
                $display_uri = esc_html(feedwordpress_display_url($uri));
                $uri = esc_html($uri);
                echo "<li><p><strong>Error:</strong> There was a problem updating <code><a href=\"{$uri}\">{$display_uri}</a></code></p></li>\n";
            }
        }
        echo "</ul>\n";
        if (!is_null($tdelta)) {
            echo "<p><strong>Update complete.</strong>" . fwp_update_set_results_message($delta) . "</p>";
            echo "\n";
            flush();
        }
        echo "</div> <!-- class=\"updated\" -->\n";
    }
}
function fwp_dashboard_update_if_requested ($object) {
	global $wpdb;

	$update_set = $object->updates_requested();

	if (count($update_set) > 0) :
		shuffle($update_set); // randomize order for load balancing purposes...

		$feedwordpress = new FeedWordPress;
		add_action('feedwordpress_check_feed', 'update_feeds_mention');
		add_action('feedwordpress_check_feed_complete', 'update_feeds_finish', 10, 3);

		$crash_ts = $feedwordpress->crash_ts();

		echo "<div class=\"update-results\">\n";
		echo "<ul>\n";
		$tdelta = NULL;
		foreach ($update_set as $uri) :
			if (!is_null($crash_ts) and (time() > $crash_ts)) :
				echo "<li><p><strong>Further updates postponed:</strong> update time limit of ".$crash_dt." second".(($crash_dt==1)?"":"s")." exceeded.</p></li>";
				break;
			endif;

			if ($uri == '*') : $uri = NULL; endif;
			$delta = $feedwordpress->update($uri, $crash_ts);
			if (!is_null($delta)) :
				if (is_null($tdelta)) :
					$tdelta = $delta;
				else :
					$tdelta['new'] += $delta['new'];
					$tdelta['updated'] += $delta['updated'];
				endif;
			else :
				$display_uri = esc_html(feedwordpress_display_url($uri));
				$uri = esc_html($uri);
				echo "<li><p><strong>Error:</strong> There was a problem updating <code><a href=\"$uri\">${display_uri}</a></code></p></li>\n";
			endif;
		endforeach;
		echo "</ul>\n";

		if (!is_null($tdelta)) :
			$mesg = array();
			if (isset($delta['new'])) : $mesg[] = ' '.$tdelta['new'].' new posts were syndicated'; endif;
			if (isset($delta['updated'])) : $mesg[] = ' '.$tdelta['updated'].' existing posts were updated'; endif;
			echo "<p>Update complete.".implode(' and', $mesg)."</p>";
			echo "\n"; flush();
		endif;
		echo "</div> <!-- class=\"updated\" -->\n";
	endif;
}