Skip to content

Commit

Permalink
Initialize WordAds at rest_api_init action, for error-free behavior i…
Browse files Browse the repository at this point in the history
…n API requests.
  • Loading branch information
jeffersonrabb committed Aug 5, 2019
1 parent 65ae218 commit 2349a05
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions modules/wordads/wordads.php
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ function get_solo_unit_css() {
*/
function __construct() {
add_action( 'wp', array( $this, 'init' ) );
add_action( 'rest_api_init', array( $this, 'init' ) );
}

/**
Expand Down

0 comments on commit 2349a05

Please sign in to comment.