* Adjust code

This commit is contained in:
zenggang
2022-06-14 06:56:01 +00:00
parent 18449b6c13
commit ea2280da59
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -119,7 +119,7 @@ class router extends baseRouter
if(isset($nullKey))$lang->{$moduleName}->{$section}[$nullKey] = $nullValue;
foreach($fields as $key => $value)
{
if($section == 'priList' and $key > 0 and $value === '') continue; // Fix bug #23538.
if($section == 'priList' and $key > 0 and trim($value) === '') continue; // Fix bug #23538.
if(!isset($lang->{$moduleName})) $lang->{$moduleName} = new stdclass();
if(!isset($lang->{$moduleName}->{$section})) $lang->{$moduleName}->{$section} = array();
+1 -1
View File
@@ -236,7 +236,7 @@ class custom extends control
$value = $data->values[$index];
$system = $data->systems[$index];
if($key and $value === '') return $this->send(array('result' => 'fail', 'message' => $this->lang->custom->notice->valueEmpty)); // Fix bug #23538.
if($key and trim($value) === '') return $this->send(array('result' => 'fail', 'message' => $this->lang->custom->notice->valueEmpty)); // Fix bug #23538.
$this->custom->setItem("{$lang}.{$module}.{$field}.{$key}.{$system}", $value);
}