AnsPress_Hooks::delete_answer( integer $post_id, object $post )

Description #

Delete answer.

Parameters #

  • $post_id
    integer (Required) Question or answer ID.
  • $post
    object (Required) Post Object.

Changelog #

VersionDescription
unknownunknown
4.1.2Introduced.

Source #

File: includes/hooks.php

	public static function delete_answer( $post_id, $post ) {
		do_action( 'ap_before_delete_answer', $post->ID, $post );

		if ( ap_is_selected( $post ) ) {
			ap_unset_selected_answer( $post->post_parent );
		}

		// Delete qameta.
		ap_delete_qameta( $post->ID );
	}

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Add your comment