WC_Privacy::delete_inactive_accounts( int $limit = 20 )

Delete inactive accounts.


Description Description


Parameters Parameters

$limit

(Optional) Limit users to process per batch.

Default value: 20


Top ↑

Return Return

(int) Number of users processed.


Top ↑

Source Source

File: includes/class-wc-privacy.php

	public static function delete_inactive_accounts( $limit = 20 ) {
		$option = wc_parse_relative_date_option( get_option( 'woocommerce_delete_inactive_accounts' ) );

		if ( empty( $option['number'] ) ) {
			return 0;
		}

		return self::delete_inactive_accounts_query( strtotime( '-' . $option['number'] . ' ' . $option['unit'] ), $limit );
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.4.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.