From 7b002db5c20993e959e98d8faa46d077298b97ff Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Wed, 29 May 2024 07:52:42 +0200 Subject: [PATCH] system: tiny cleanup in previous --- src/www/system_hasync.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/www/system_hasync.php b/src/www/system_hasync.php index 9c3f9cd91..f634bc3a9 100644 --- a/src/www/system_hasync.php +++ b/src/www/system_hasync.php @@ -32,11 +32,11 @@ require_once("interfaces.inc"); $a_hasync = &config_read_array('hasync'); -$checkbox_names = array( - 'pfsyncenabled', +$checkbox_names = [ 'disablepreempt', - 'disconnectppps' -); + 'disconnectppps', + 'pfsyncenabled', +]; $syncplugins = plugins_xmlrpc_sync(); @@ -45,7 +45,7 @@ foreach (array_keys($syncplugins) as $key) { } if ($_SERVER['REQUEST_METHOD'] === 'GET') { - $pconfig = array(); + $pconfig = []; foreach ($checkbox_names as $name) { if (isset($a_hasync[$name])) { $pconfig[$name] = $a_hasync[$name]; @@ -53,7 +53,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { $pconfig[$name] = null; } } - foreach (array('pfsyncpeerip','pfsyncinterface','synchronizetoip','username','password') as $tag) { + foreach (['pfsyncpeerip', 'pfsyncinterface', 'synchronizetoip', 'username', 'password'] as $tag) { if (isset($a_hasync[$tag])) { $pconfig[$tag] = $a_hasync[$tag]; } else { @@ -61,7 +61,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { } } } elseif ($_SERVER['REQUEST_METHOD'] === 'POST') { - $input_errors = array(); + $input_errors = []; $pconfig = $_POST; foreach ($checkbox_names as $name) {