PluginProbe
Fluent Support – Helpdesk & Customer Support Ticket System / 2.4.5
Fluent Support – Helpdesk & Customer Support Ticket System v2.4.5
2.4.5 2.4.0 2.3.2 2.3.1 2.3.0 2.2.1 2.2.0 trunk 1.10.0 1.10.1 1.10.2 1.10.3 1.10.4 1.10.5 1.4.0 1.4.1 1.4.2 1.4.5 1.4.6 1.4.7 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 All 69 releases
← All changes | app/Services/Integrations/FluentForm/FeedIntegration.php +11 -10 1.10.5 → 2.4.5 View file →
@@ -292,9 +292,10 @@
292 292 continue;
293 293 }
294 294
295 295 if( $type=='checkbox' && array_key_exists($slug, $ticketCustomField)) {
296 - $ticketCustomField[$slug] = explode(',', Arr::get($ticketCustomField, $slug));
296 + $value = Arr::get($ticketCustomField, $slug, '');
297 + $ticketCustomField[$slug] = $value ? explode(',', (string)$value) : [];
297 298 } else {
298 299 $ticketCustomField[$slug] = Arr::get($ticketCustomField, $slug);
299 300 }
300 301 }
@@ -301,13 +302,14 @@
301 302
302 303 $ticketData = [
303 304 'product_source' => 'local',
304 305 'mailbox_id' => Arr::get($data, 'list_id'),
305 - 'title' => sanitize_text_field(wp_unslash(Arr::get($data, 'ticket_title'))),
306 - 'content' => wp_unslash(wp_kses_post(Arr::get($data, 'ticket_content'))),
306 + // Feed settings and entry values are stored unslashed, so sanitize only.
307 + 'title' => sanitize_text_field(Arr::get($data, 'ticket_title')),
308 + 'content' => wp_kses_post(Arr::get($data, 'ticket_content')),
307 309 'attachments' => sanitize_text_field(Arr::get($data, 'ticket_attachments')),
308 - 'client_priority' => strtolower(sanitize_text_field(Arr::get($data, 'client_priority'))),
309 - 'priority' => strtolower(sanitize_text_field(Arr::get($data, 'client_priority'))),
310 + 'client_priority' => strtolower(sanitize_text_field(Arr::get($data, 'client_priority', ''))),
311 + 'priority' => strtolower(sanitize_text_field(Arr::get($data, 'client_priority', ''))),
310 312 'custom_fields' => $ticketCustomField,
311 313 'source' => 'web'
312 314 ];
313 315
@@ -450,13 +452,12 @@
450 452 'is_media_library' => $isMediaLibrary,
451 453 'attachment_id' => $attachmentId
452 454 ]);
453 455 } catch (\Exception $e) {
454 - error_log("Failed to create attachment record: " . $e->getMessage());
456 +
455 457 }
456 458 }
457 459 } catch (\Exception $e) {
458 - error_log("Error processing attachment: " . $e->getMessage());
459 460 continue;
460 461 }
461 462 }
462 463
@@ -480,12 +481,12 @@
480 481 private function isBlockedCustomer($customerEmail)
481 482 {
482 483 $customer = Customer::where('email', $customerEmail)->first();
483 484
484 - if('inactive' == $customer->status || !$customer->status) {
485 - return true;
485 + if (!$customer) {
486 + return false;
486 487 }
487 488
488 - return false;
489 + return $customer->isBlocked();
489 490 }
490 491
491 492 }