Plugin Directory

Changeset 3320182


Ignore:
Timestamp:
06/30/2025 05:04:21 PM (8 months ago)
Author:
echoai
Message:

Update EchoAI plugin to version 2.2.6

Location:
echoai
Files:
63 added
3 edited

Legend:

Unmodified
Added
Removed
  • echoai/trunk/echoai.php

    r3320158 r3320182  
    1111 * Author URI:          https://echoaichat.com/contact
    1212 * Text Domain:         echoai
    13  * Version:             2.2.5
     13 * Version:             2.2.6
    1414 * Requires at least:   5.9
    1515 * Requires PHP:        7.4
     
    5252define('ECHOAI_MENU_ICON', ECHOAI_PLUGIN_URL . 'images/menu-icon.svg');
    5353define('ECHOAI_JSSDK', "https://cdn.echoaichat.com/sdk/echo-sdk.js");
    54 define('ECHOAI_SETUP_VERSION', '2.2.5');
     54define('ECHOAI_SETUP_VERSION', '2.2.6');
    5555define('ECHOAI_TERMS_URL', "https://echoaichat.com/");
    5656define('ECHOAI_DOCS_URL', "https://echoaichat.com/");
  • echoai/trunk/lib/admin-pages.php

    r3320158 r3320182  
    262262    function echoai_check_network()
    263263    {
     264        // Skip during AJAX and REST API requests
     265        if (wp_doing_ajax() || (defined('REST_REQUEST') && REST_REQUEST)) {
     266            return;
     267        }
     268
    264269        $screen = get_current_screen();
    265270
    266271        if (
     272            $screen &&
    267273            ECHOAI_BYPASS_NETWORK_CHECK !== true &&
    268274            ($screen->id === 'toplevel_page_echoai' || $screen->id === 'echoai_page_echoai_config') &&
     
    294300function echoai_validate_saved_assistant_id()
    295301{
     302    // Skip validation during AJAX requests and REST API calls
     303    if (wp_doing_ajax() || (defined('REST_REQUEST') && REST_REQUEST)) {
     304        return;
     305    }
     306
    296307    // Only run if user is on an admin page and has appropriate permissions
    297308    if (is_admin() && current_user_can('manage_options')) {
     
    315326
    316327                // Add an admin notice about the validation issue without deleting the ID
    317                 add_action('admin_notices', function() {
    318                     ?>
    319                     <div class="notice notice-warning is-dismissible">
    320                         <p><?php _e('Could not validate your ECHO AI Assistant ID. Please check your connection and try again.', 'echoai'); ?></p>
    321                     </div>
    322                     <?php
    323                 });
     328                // Only show notices on regular admin pages, not during AJAX/REST requests
     329                if (!wp_doing_ajax() && (!defined('REST_REQUEST') || !REST_REQUEST)) {
     330                    add_action('admin_notices', function() {
     331                        ?>
     332                        <div class="notice notice-warning is-dismissible">
     333                            <p><?php _e('Could not validate your ECHO AI Assistant ID. Please check your connection and try again.', 'echoai'); ?></p>
     334                        </div>
     335                        <?php
     336                    });
     337                }
    324338            }
    325339        }
  • echoai/trunk/readme.txt

    r3320158 r3320182  
    55Requires at least: 5.9
    66Tested up to: 6.6
    7 Stable tag: 2.2.5
     7Stable tag: 2.2.6
    88Requires PHP: 7.4
    99License: GPLv2 or later
     
    157157== Changelog ==
    158158
     159= 2.2.6 =
     160- Fixed: Widget editor JSON error when plugin is activated
     161- Fixed: Prevented validation checks during AJAX and REST API requests
     162- Fixed: Admin notices no longer interfere with JSON responses
     163- Improved: Better compatibility with WordPress admin AJAX operations
     164
    159165= 2.2.5 =
    160166- Fixed: Assistant ID no longer gets deleted during plugin activation/deactivation
Note: See TracChangeset for help on using the changeset viewer.