LLMS_REST_Sections_Controller::check_read_permission( LLMS_Section $section )
Checks if a Section can be read
Parameters Parameters
- $section
-
(LLMS_Section) (Required) The Section oject.
Return Return
(bool) Whether the post can be read.
Source Source
File: libraries/lifterlms-rest/includes/server/class-llms-rest-sections-controller.php
* * @param LLMS_Section $section The Section oject. * @return bool Whether the post can be read. */ protected function check_read_permission( $section ) { /** * As of now, sections of password protected courses cannot be read */ if ( post_password_required( $section->get( 'parent_course' ) ) ) { return false; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.0.0-beta.1 | Introduced. |