Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit 372e4bc

Browse files
author
the-djmaze
committed
Rename application.ini [labs]log_ajax_response_write_limit to [logs]json_response_write_limit
1 parent 17fc379 commit 372e4bc

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

snappymail/v/0.0.0/app/libraries/RainLoop/Config/Application.php

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,10 @@ public function Set(string $sSectionKey, string $sParamKey, $mParamValue) : void
132132
$sSectionKey = 'login';
133133
$sParamKey = 'fault_delay';
134134
}
135+
if ('log_ajax_response_write_limit' === $sParamKey) {
136+
$sSectionKey = 'logs';
137+
$sParamKey = 'json_response_write_limit';
138+
}
135139
}
136140
parent::Set($sSectionKey, $sParamKey, $mParamValue);
137141
}
@@ -379,7 +383,9 @@ protected function defaultValues() : array
379383
'auth_logging' => array(false, 'Enable auth logging in a separate file (for fail2ban)'),
380384
'auth_logging_filename' => array('fail2ban/auth-{date:Y-m-d}.txt'),
381385
'auth_logging_format' => array('[{date:Y-m-d H:i:s}] Auth failed: ip={request:ip} user={imap:login} host={imap:host} port={imap:port}'),
382-
'auth_syslog' => array(false, 'Enable auth logging to syslog for fail2ban')
386+
'auth_syslog' => array(false, 'Enable auth logging to syslog for fail2ban'),
387+
388+
'json_response_write_limit' => array(300),
383389
),
384390

385391
'debug' => array(
@@ -422,7 +428,6 @@ protected function defaultValues() : array
422428

423429
'labs' => array(
424430
'allow_message_append' => array(false, 'Allow drag & drop .eml files from system into messages list'),
425-
'log_ajax_response_write_limit' => array(300),
426431
'smtp_show_server_errors' => array(false),
427432
'mail_func_clear_headers' => array(true, 'PHP mail() remove To and Subject headers'),
428433
'mail_func_additional_parameters' => array(false, 'PHP mail() set -f emailaddress'),

snappymail/v/0.0.0/app/libraries/RainLoop/ServiceActions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ public function ServiceJson() : string
183183
$this->oActions->logException($oException, \LOG_ERR);
184184
}
185185

186-
$iLimit = (int) $this->Config()->Get('labs', 'log_ajax_response_write_limit', 0);
186+
$iLimit = (int) $this->Config()->Get('logs', 'json_response_write_limit', 0);
187187
$this->oActions->logWrite(0 < $iLimit && $iLimit < \strlen($sResult)
188188
? \substr($sResult, 0, $iLimit).'...' : $sResult, \LOG_INFO, 'JSON');
189189
}

0 commit comments

Comments
 (0)