Plugin Directory

Changeset 3464031


Ignore:
Timestamp:
02/18/2026 07:57:29 AM (7 weeks ago)
Author:
niaj
Message:

@v-2.1.3

Location:
ghl-wizard
Files:
78 added
6 edited

Legend:

Unmodified
Added
Removed
  • ghl-wizard/trunk/api/get-token.php

    r3400822 r3464031  
    77   
    88    if ( ! str_contains( $referrer, 'gohighlevel') ) {
    9         return '';
     9        return;
     10    }
     11
     12    if ( ! current_user_can( 'manage_options' ) ) {
     13        return;
    1014    }
    1115
  • ghl-wizard/trunk/ghl-wizard.php

    r3456358 r3464031  
    55 * Plugin URI:        https://betterwizard.com/lead-connector-wizard/
    66 * Description:       Connect WordPress with the popular LeadConnector CRM(HighLevel) and combine the power of automation and excellent user experience. Including memberships, content protection, WooCommerce automation, custom fields & many more...
    7  * Version:           2.1.2
     7 * Version:           2.1.3
    88 * Author:            Better Wizard
    99 * Author URI:        https://connectorwizard.app/
  • ghl-wizard/trunk/inc/content-protection.php

    r3392946 r3464031  
    267267        // }
    268268
     269        if ( wp_is_serving_rest_request() || wp_doing_ajax() ) {
     270            wp_send_json_error(
     271                [
     272                    'code'    => 'no_access',
     273                    'message' => 'You do not have permission to access this content.',
     274                ],
     275                403
     276            );
     277        }       
     278       
    269279        $default_no_access_redirect_to = get_option( 'default_no_access_redirect_to' );
    270280        $post_redirect_to = get_post_meta($post_id, 'hlwpw_no_access_redirect_to', true);
     
    575585    $learndash_course_ids = get_posts(array(
    576586        'numberposts' => -1,
    577         'post_type' => 'sfwd-courses',
     587        'post_type' => array( 'sfwd-courses', 'groups' ),
    578588        'fields' => 'ids',
    579589        'meta_query' => array(
     
    609619                    }
    610620                }
    611                 ld_update_course_access(  $user_id, $ld_id, $should_enroll );
     621               
     622                $post_type = get_post_type( $ld_id );
     623               
     624                if ( $post_type === 'sfwd-courses' ) {
     625                    ld_update_course_access( $user_id, $ld_id, $should_enroll );
     626                } elseif ( $post_type === 'groups' ) {
     627                    ld_update_group_access( $user_id, $ld_id, $should_enroll );
     628                }
    612629            }
    613630        }
  • ghl-wizard/trunk/inc/filters.php

    r3430533 r3464031  
    2222 */
    2323function lcw_redirect_user_after_login() {
     24
     25    // Skip if in admin or REST/AJAX request
     26    if ( is_admin() || ( defined( 'REST_REQUEST' ) && REST_REQUEST ) || ( defined( 'DOING_AJAX' ) && DOING_AJAX ) ) {
     27        return;
     28    }
     29
    2430    if ( current_user_can( 'manage_options' ) ) {
    2531        return;
    2632    }
     33
    2734    $is_login_redirect_enabled = get_option( 'lcw_enable_login_redirect' );
    2835    if ( ! empty( $is_login_redirect_enabled ) ) {
     
    3946 */
    4047function lcw_redirect_user_after_logout() {
     48   
     49    // Skip if in admin or REST/AJAX request
     50    if ( is_admin() || ( defined( 'REST_REQUEST' ) && REST_REQUEST ) || ( defined( 'DOING_AJAX' ) && DOING_AJAX ) ) {
     51        return;
     52    }
     53
    4154    $is_logout_redirect_enabled = get_option( 'lcw_enable_logout_redirect' );
    4255    if ( ! empty( $is_logout_redirect_enabled ) ) {
  • ghl-wizard/trunk/inc/metaboxes.php

    r3392946 r3464031  
    231231
    232232            // LearnDash auto enrollment tags
    233             if ( get_post_type() == 'sfwd-courses' ) {
     233            if ( get_post_type() == 'sfwd-courses' || get_post_type() == 'groups' ) {
    234234                $metabox_html .= "<p>";
    235235                    $metabox_html .= "<label for='lcw_ld_auto_enrollment_tags'>";
  • ghl-wizard/trunk/readme.txt

    r3456358 r3464031  
    66Tested up to: 6.9
    77Requires PHP: 7.4
    8 Stable tag: 2.1.2
     8Stable tag: 2.1.3
    99License: GPLv3
    1010License URI: https://www.gnu.org/licenses/gpl-3.0.html
     
    190190
    191191== 🎓 LearnDash Integration ==
    192 - Automatically enroll users in LearnDash courses based on their access to specific courses or content.
    193 - Remove users from courses when their access is revoked, ensuring they no longer have access to the course content.
    194 - Enhance the learning experience by dynamically managing course enrollment based on user access levels.
     192
     193- Automatically enroll users in LearnDash courses based on contact tags.
     194- Remove users from courses when the specific contact tags are removed.
     195- Automatically enroll users in and remove them from LearnDash groups based on contact tags.
    195196
    196197== 🖌️ Elementor Page Builder Integration ==
     
    218219
    219220== Changelog ==
     221
     222= 2.1.2 - 08 Feb 2026 =
     223* Auto Enrollment to LearnDash groups by contact tags
     224* REST access modified for the redirection
    220225
    221226= 2.1.2 - 08 Feb 2026 =
Note: See TracChangeset for help on using the changeset viewer.