Inventory_Presser_Admin_Photo_Arranger::delete_attachment_handler( mixed $post_id, mixed $post )

delete_attachment_handler


Parameters Parameters

$post_id

(mixed) (Required)

$post

(mixed) (Required)


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/admin/class-admin-photo-arranger.php

	public function delete_attachment_handler( $post_id, $post ) {
		$attachment = get_post( $post_id );
		if ( empty( $attachment->post_parent ) ) {
			return;
		}
		$this->remove_attachment_from_gallery( $post_id, $attachment->post_parent );
	}