minor fix

This commit is contained in:
alejandro.campos@artica.es 2024-02-01 17:36:21 +01:00
parent 44e546af39
commit 05af441f19
1 changed files with 8 additions and 2 deletions

View File

@ -1145,7 +1145,7 @@ class ConsoleSupervisor
public function checkAttachment()
{
global $config;
hd("dadsada", true);
if (is_writable($config['attachment_store']) !== true) {
$this->notify(
[
@ -1163,6 +1163,12 @@ hd("dadsada", true);
$this->cleanNotifications('NOTIF.WRITABLE.ATTACHMENT');
}
$filecount = $this->countFiles(
$config['attachment_store'],
'',
$config['num_files_attachment']
);
if ($filecount > $config['num_files_attachment']) {
$this->notify(
[
@ -1291,7 +1297,7 @@ hd("dadsada", true);
$filecount = (int) modules_get_last_value($moduleId);
}
}
hd($filecount, true);
// If cannot open directory, count is '-1', skip.
if ($filecount > $MAX_FILES_DATA_IN) {
$this->notify(