/**
 * Ouput the single lesson meta
 *
 * The function should only be called on the single lesson
 *
 */
function sensei_the_single_lesson_meta()
{
    // if the lesson meta is included within theme load that instead of the function content
    $template = Sensei_Templates::locate_template('single-lesson/lesson-meta.php');
    if (!empty($template)) {
        Sensei_Templates::get_template('single-lesson/lesson-meta.php');
        return;
    }
    // Get the meta info
    $lesson_course_id = absint(get_post_meta(get_the_ID(), '_lesson_course', true));
    $is_preview = Sensei_Utils::is_preview_lesson(get_the_ID());
    // Complete Lesson Logic
    do_action('sensei_complete_lesson');
    // Check that the course has been started
    if (Sensei()->access_settings() || Sensei_Utils::user_started_course($lesson_course_id, get_current_user_id()) || $is_preview) {
        ?>
        <section class="lesson-meta">
            <?php 
        if (apply_filters('sensei_video_position', 'top', get_the_ID()) == 'bottom') {
            do_action('sensei_lesson_video', get_the_ID());
        }
        ?>
            <?php 
        do_action('sensei_frontend_messages');
        ?>

            <?php 
        if (!$is_preview || Sensei_Utils::user_started_course($lesson_course_id, get_current_user_id())) {
            sensei_do_deprecated_action('sensei_lesson_quiz_meta', '1.9.0', 'sensei_single_lesson_content_inside_before', array(get_the_ID(), get_current_user_id()));
        }
        ?>
        </section>

        <?php 
        do_action('sensei_lesson_back_link', $lesson_course_id);
        ?>

    <?php 
    }
    do_action('sensei_lesson_meta_extra', get_the_ID());
}
 /**
  * sensei_locate_template function.
  *
  * @access public
  * @param mixed $template_name
  * @param string $template_path (default: '')
  * @param string $default_path (default: '')
  * @return void
  */
 function sensei_locate_template($template_name, $template_path = '', $default_path = '')
 {
     _deprecated_function('sensei_locate_template', '1.9.0', 'Sensei_Templates::locate_template');
     Sensei_Templates::locate_template($template_name, $template_path, $default_path);
 }