Some code cleanup

This commit is contained in:
James Cole
2024-03-16 06:28:21 +01:00
parent 060c9648f1
commit 441a8a8408
3 changed files with 181 additions and 180 deletions

View File

@@ -237,6 +237,7 @@ class AttachmentHelper implements AttachmentHelperInterface
if (0 === $file->getSize()) { if (0 === $file->getSize()) {
$this->errors->add('attachments', trans('validation.file_zero_length')); $this->errors->add('attachments', trans('validation.file_zero_length'));
return null; return null;
} }

View File

@@ -109,7 +109,7 @@ class SearchRuleEngine implements RuleEngineInterface
continue; continue;
} }
$contextSearch = $ruleTrigger->trigger_type; $contextSearch = $ruleTrigger->trigger_type;
if(str_starts_with($ruleTrigger->trigger_type, '-')) { if (str_starts_with($ruleTrigger->trigger_type, '-')) {
$contextSearch = substr($ruleTrigger->trigger_type, 1); $contextSearch = substr($ruleTrigger->trigger_type, 1);
} }