title: remove_action From PHP Class
body: <p>I'm attempting to remove an action and add it with a different priority.
  Below are all the code snippets that assist in generating a Message:</p>
  
  <p><b>Include required frontend files</b></p>
  
  <pre><code>private function frontend_includes() {
  
      require_once( $this-&gt;get_plugin_path() . '/includes/wc-memberships-template-functions.php' );
      require_once( $this-&gt;get_plugin_path() . '/includes/class-wc-memberships-shortcodes.php' );
  
      WC_Memberships_Shortcodes::initialize();
  
      $this-&gt;frontend     = $this-&gt;load_class( '/includes/frontend/class-wc-memberships-frontend.php', 'WC_Memberships_Frontend' );
      $this-&gt;checkout     = $this-&gt;load_class( '/includes/frontend/class-wc-memberships-checkout.php', 'WC_Memberships_Checkout' );
      $this-&gt;restrictions = $this-&gt;load_class( '/includes/frontend/class-wc-memberships-restrictions.php', 'WC_Memberships_Restrictions' );
  }
  </code></pre>
  
  <p><b>Get the product purchasing restricted message</b></p>
  
  <pre><code> /**
   * @param int $post_id Optional. Defaults to current post.
   * @return string
   */
  public function get_product_purchasing_restricted_message( $post_id = null ) {
  
      if ( ! $post_id ) {
  
          global $post;
          $post_id = $post-&gt;ID;
      }
  
      $products = $this-&gt;get_products_that_grant_access( $post_id );
      $message  = $this-&gt;get_restriction_message( 'product_purchasing_restricted', $post_id, $products );
  
      /**
       * Filter the product purchasing restricted message
       *
       * @since 1.0.0
       * @param string $message The restriction message
       * @param int $product_id ID of the product being restricted
       * @param array $products Array of product IDs that grant access to this product
       */
      return apply_filters( 'wc_memberships_product_purchasing_restricted_message', $message, $post_id, $products );
  }
  </code></pre>
  
  <p><b>Restriction class, handles content restriction on frontend</b></p>
  
  <pre><code>class WC_Memberships_Restrictions {
  
  
  /** @var array associative array of content conditions for current user **/
  private $user_content_access_conditions;
  
  /** @var array of post IDs that content restriction has been applied to **/
  private $content_restriction_applied = array();
  
  /** @var string Product content restriction password helper **/
  private $product_restriction_password = null;
  
  /** @var bool Product thumbnail removed helper **/
  private $product_thumbnail_restricted = false;
  
  
  public function __construct() {
      // Desired action to remove and re-prioritize
      add_action( 'woocommerce_single_product_summary', array( $this, 'single_product_purchasing_restricted_message' ), 30 );
  }
  }
  </code></pre>
  
  <p>I literally just need to alter the priority to 15 from 30 in the action of the WC_Memberships_Restrictions class. The issue is that there's no clear way to call the removal. Any suggestions?</p>