message = $message; } /** * Registers hooks to WordPress. This is a separate function so you can * control when the hooks are registered. */ public function register_hooks() { global $whip_admin_notices_added; if ( null === $whip_admin_notices_added || ! $whip_admin_notices_added ) { add_action( 'admin_notices', array( $this, 'renderMessage' ) ); $whip_admin_notices_added = true; } } /** * Renders the messages present in the global to notices. */ public function renderMessage() { printf( '