| @@ -42,21 +42,4 @@ | ||
| 42 | 42 | } |
| 43 | 43 | |
| 44 | 44 | // Update Access Token when refreshed by the API class. |
| 45 | 45 | add_action( 'wp_to_buffer_api_refresh_token', 'wp_to_buffer_update_credentials', 10, 3 ); |
| 46 | - | |
| 47 | -/** | |
| 48 | - * Schedules the WordPress Cron event to refresh the access token before it expires. | |
| 49 | - * | |
| 50 | - * Runs whenever an access token is refreshed, so that each token schedules the | |
| 51 | - * refresh of its successor. | |
| 52 | - * | |
| 53 | - * @since 6.2.0 | |
| 54 | - */ | |
| 55 | -function wp_to_buffer_schedule_refresh_token_event() { | |
| 56 | - | |
| 57 | - WP_To_Buffer::get_instance()->get_class( 'cron' )->reschedule_refresh_token_event(); | |
| 58 | - | |
| 59 | -} | |
| 60 | - | |
| 61 | -// Schedule the next token refresh whenever a token is refreshed. | |
| 62 | -add_action( 'wp_to_buffer_api_refresh_token', 'wp_to_buffer_schedule_refresh_token_event', 20 ); | |