LLMS_Blocks_Post_Visibility::authorize_callback( bool $allowed, string $meta_key, int $object_id, int $user_id, string $cap, array $caps )
Meta field update authorization callback.
Parameters Parameters
- $allowed
-
(bool) (Required) Is the update allowed.
- $meta_key
-
(string) (Required) Meta keyname.
- $object_id
-
(int) (Required) WP Object ID (post,comment,etc)...
- $user_id
-
(int) (Required) WP User ID.
- $cap
-
(string) (Required) requested capability.
- $caps
-
(array) (Required) user capabilities.
Return Return
(bool)
Source Source
File: libraries/lifterlms-blocks/includes/class-llms-blocks-post-visibility.php
public function authorize_callback( $allowed, $meta_key, $object_id, $user_id, $cap, $caps ) { return user_can( $user_id, 'edit_post', $object_id ); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.3.0 | Introduced. |