classes/PodsAdmin.php
public function admin_setup_delete( $id, $obj ) {

		$pod = pods_api()->load_pod( array( 'id' => $id ), false );

		if ( empty( $pod ) ) {
			return $obj->error( __( 'Pod not found.', 'pods' ) );
		}

		pods_api()->delete_pod( array( 'id' => $id ) );

		unset( $obj->data[ $pod['id'] ] );

		$obj->total       = count( $obj->data );
		$obj->total_found = count( $obj->data );

		$obj->message( __( 'Pod deleted successfully.', 'pods' ) );
	}
public function admin_setup_delete( $id, $obj ) {

		$pod = pods_api()->load_pod( array( 'id' => $id ), false );

		if ( empty( $pod ) ) {
			return $obj->error( __( 'Pod not found.', 'pods' ) );
		}

		pods_api()->delete_pod( array( 'id' => $id ) );

		unset( $obj->data[ $pod['id'] ] );

		$obj->total       = count( $obj->data );
		$obj->total_found = count( $obj->data );

		$obj->message( __( 'Pod deleted successfully.', 'pods' ) );
	}
public function admin_setup_delete ( $ id , $ obj ) { $ pod = pods_api ( ) -> load_pod ( array ( 'id' => $ id ) , false ) ; if ( empty ( $ pod ) ) { return $ obj -> error ( __ ( 'Pod not found.' , 'pods' ) ) ; } pods_api ( ) -> delete_pod ( array ( 'id' => $ id ) ) ; unset ( $ obj -> data [ $ pod [ 'id' ] ] ) ; $ obj -> total = count ( $ obj -> data ) ; $ obj -> total_found = count ( $ obj -> data ) ; $ obj -> message ( __ ( 'Pod deleted successfully.' , 'pods' ) ) ; }
Delete a pod

@param int|string $id  Item ID.
@param PodsUI     $obj PodsUI object.

@return mixed
Delete a pod