Skip to content

Commit

Permalink
Fix. FW update. Empty error on RC call fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandergull committed Feb 8, 2025
1 parent 4ca9002 commit c9e201d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion inc/fw-update.php
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,14 @@ function spbc_security_firewall_update__worker($checker_work = null)
);

if ( ! empty($result['error']) ) {
$spbc->error_add('firewall_update', current(array_column($queue->queue['stages'], 'error')));
$stage_error = current(array_column($queue->queue['stages'], 'error'));
if ( empty($stage_error) ) {
$stage_error = esc_html($result['error']);
if (empty($stage_error)) {
$stage_error = __('unknown remote call error', 'security-malware-firewall');
}
}
$spbc->error_add('firewall_update', $stage_error);
}

return ! empty($result['error']) && $queue->isQueueFinished() ? $result : true;
Expand Down

0 comments on commit c9e201d

Please sign in to comment.