l3rady/wp-updates-notifier — pull request #4 by l3rady (2013-03-27 17:13:28+00:00)
Title: Use wp_get_schedules() to get available schedules

Use wp_get_schedules() to get available schedules instead of manually hardcoding the default WordPress ones.

Doing this will easily allow others to create new schedules tobe included in WordPress and be used by this plugin.

For example if someone wants this plugin to run weekly they can create a weekly schedule like so:

add_filter( 'cron_schedules', 'cron_add_weekly' );

function cron_add_weekly( $schedules ) {
// Adds once weekly to the existing schedules.
$schedules['weekly'] = array(
'interval' => 604800,
'display' => __( 'Once Weekly' )
);

return $schedules;
}