Added refresh cron and refresh method

This commit is contained in:
Justin Foell
2019-06-03 14:27:14 -05:00
parent 15de60d764
commit cfdf3aae9e
5 changed files with 128 additions and 15 deletions
+3 -2
View File
@@ -46,11 +46,12 @@ class WPStrava {
*/
private function __construct() {
$this->settings = new WPStrava_Settings();
$this->auth = WPStrava_Auth::get_auth( 'forever' );
$this->auth = WPStrava_Auth::get_auth( 'refresh' );
$this->auth->hook();
if ( is_admin() ) {
$this->settings->hook();
$this->auth->hook();
} else {
add_action( 'init', array( $this, 'register_shortcodes' ) );
add_action( 'wp_enqueue_scripts', array( $this, 'register_scripts' ) );