Automattic\WooCommerce\Internal\ProductDownloads\ApprovedDirectories\Admin

SyncUI::security_check()privateWC 1.0

Makes sure the user has appropriate permissions and that we have a valid nonce.

Method of the class: SyncUI{}

No Hooks.

Return

null. Nothing (null).

Usage

// private - for code of main (parent) class only
$result = $this->security_check();

SyncUI::security_check() code WC 8.6.1

private function security_check() {
	if ( ! Users::is_site_administrator() ) {
		wp_die( esc_html__( 'You do not have permission to modify the list of approved directories for product downloads.', 'woocommerce' ) );
	}
}