Elementor\Editor::get_locked_user PHP Method

get_locked_user() public method

public get_locked_user ( $post_id ) : boolean | WP_User
$post_id
return boolean | WP_User
    public function get_locked_user($post_id)
    {
        if (!function_exists('wp_check_post_lock')) {
            require_once ABSPATH . 'wp-admin/includes/post.php';
        }
        $locked_user = wp_check_post_lock($post_id);
        if (!$locked_user) {
            return false;
        }
        return get_user_by('id', $locked_user);
    }