PluginProbe
WPBot – AI ChatBot for Live Support, Lead Generation, WordPress Automation, AI Services / 8.8.0
WPBot – AI ChatBot for Live Support, Lead Generation, WordPress Automation, AI Services v8.8.0
8.8.0 8.7.9 8.7.8 8.7.7 8.7.6 8.7.5 8.7.4 8.7.3 8.7.2 8.7.1 8.7.0 8.6.9 8.6.8 8.6.7 8.6.6 8.6.5 8.6.4 8.6.2 8.6.1 8.6.0 8.5.9 8.5.8 8.5.7 8.5.6 8.5.5 All 536 releases
← All changes | includes/integration/openai/qcld-bot-openai.php +4 -3 8.7.3 → 8.8.0 View file →
@@ -541,8 +541,9 @@
541 541 'messages' => $messages,
542 542 'stream' => true,
543 543 ] );
544 544
545 + // phpcs:disable WordPress.WP.AlternativeFunctions.curl_curl_init, WordPress.WP.AlternativeFunctions.curl_curl_setopt, WordPress.WP.AlternativeFunctions.curl_curl_exec, WordPress.WP.AlternativeFunctions.curl_curl_errno, WordPress.WP.AlternativeFunctions.curl_curl_error, WordPress.WP.AlternativeFunctions.curl_curl_close -- SSE streaming requires cURL write callback.
545 546 $ch = curl_init( 'https://api.openai.com/v1/chat/completions' );
546 547 curl_setopt( $ch, CURLOPT_POST, true );
547 548 curl_setopt( $ch, CURLOPT_HTTPHEADER, $headers );
548 549 curl_setopt( $ch, CURLOPT_POSTFIELDS, $post_data );
@@ -557,8 +558,9 @@
557 558 echo 'data: [ERROR] ' . esc_html( curl_error( $ch ) ) . "\n\n"; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- curl_error is already escaped above
558 559 flush();
559 560 }
560 561 curl_close( $ch );
562 + // phpcs:enable WordPress.WP.AlternativeFunctions.curl_curl_init, WordPress.WP.AlternativeFunctions.curl_curl_setopt, WordPress.WP.AlternativeFunctions.curl_curl_exec, WordPress.WP.AlternativeFunctions.curl_curl_errno, WordPress.WP.AlternativeFunctions.curl_curl_error, WordPress.WP.AlternativeFunctions.curl_curl_close
561 563 do_action( 'qcld_openai_user_rate_cal', 1 );
562 564 exit;
563 565 }
564 566
@@ -892,8 +894,9 @@
892 894 if( $ai_enabled == 1 ){
893 895 update_option('qcld_openrouter_enabled',0);
894 896 update_option('qcld_grok_enabled',0);
895 897 update_option('qcld_gemini_enabled',0);
898 + update_option('qcld_claude_enabled',0);
896 899 update_option('disable_wp_chatbot_site_search',1);
897 900 }
898 901
899 902 update_option('qcld_openai_relevant_enabled',$is_relevant_enabled);
@@ -1342,9 +1345,9 @@
1342 1345 if (isset($form['email'])) {
1343 1346 $email_enabled = $form['email'] == 1;
1344 1347 }
1345 1348 $per_action_emails = isset($form['email_addresses']) ? trim($form['email_addresses']) : '';
1346 - error_log('[WPBot AI] Matched form: "' . $form['title'] . '" | email_addresses stored: "' . $per_action_emails . '"');
1349 + //error_log('[WPBot AI] Matched form: "' . $form['title'] . '" | email_addresses stored: "' . $per_action_emails . '"');
1347 1350 break;
1348 1351 }
1349 1352 }
1350 1353 }
@@ -1356,10 +1359,8 @@
1356 1359 } else {
1357 1360 $default = get_option('qlcd_wp_chatbot_admin_email', '');
1358 1361 $to = !empty($default) ? array_map('trim', explode(',', $default)) : get_option('admin_email');
1359 1362 }
1360 - error_log('[WPBot AI] Sending email to: ' . print_r($to, true));
1361 - error_log('[WPBot AI] Reply-To email: ' . $reply_to);
1362 1363 $subject = sanitize_text_field($data['form_title']) . " - " . esc_html__('New AI Chat Submission', 'chatbot');
1363 1364 $headers = array('Content-Type: text/html; charset=UTF-8');
1364 1365 if (!empty($reply_to)) {
1365 1366 $headers[] = 'Reply-To: ' . $reply_to;