wp plugin udapted v1.5.0

This commit is contained in:
IGNY8 VPS (Salman)
2026-01-13 08:19:55 +00:00
parent 17b3811d4c
commit 3cc2e6b270
13 changed files with 1078 additions and 273 deletions

View File

@@ -360,21 +360,14 @@ if (!function_exists('igny8_is_connection_enabled')) {
*/
function igny8_get_connection_state() {
$api_key = function_exists('igny8_get_secure_option') ? igny8_get_secure_option('igny8_api_key') : get_option('igny8_api_key');
$integration_id = get_option('igny8_integration_id');
$last_structure_sync = get_option('igny8_last_structure_sync');
if (empty($api_key)) {
igny8_log_connection_state('not_connected', 'No API key found');
return 'not_connected';
}
if (!empty($api_key) && !empty($integration_id) && !empty($last_structure_sync)) {
igny8_log_connection_state('connected', 'Fully connected and synced');
return 'connected';
}
igny8_log_connection_state('configured', 'API key set, pending structure sync');
return 'configured';
igny8_log_connection_state('connected', 'API key configured');
return 'connected';
}
/**