llms_rest_validate_memberships( int|int[] $memberships, boolean $allow_empty = false )
Validate submitted integer, or array of integers is an array of real memberships id, or empty.
Parameters Parameters
- $memberships
-
(int|int[]) (Required) Array of memberships id.
- $allow_empty
-
(boolean) (Optional) Whether or not allowing empty lists.
Default value: false
Return Return
(boolean)
Source Source
File: libraries/lifterlms-rest/includes/server/llms-rest-server-functions.php
function llms_rest_validate_memberships( $memberships, $allow_empty = false ) { return llms_rest_validate_post_types( $memberships, 'llms_membership', $allow_empty ); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.0.0-beta.18 | Introduced. |