mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 01:28:19 +01:00
Add a error log but does not block if trigger name is wrong
This commit is contained in:
@@ -87,8 +87,9 @@ trait CommonTrigger
|
|||||||
|
|
||||||
if (!empty($this->TRIGGER_PREFIX) && strpos($triggerName, $this->TRIGGER_PREFIX . '_') !== 0) {
|
if (!empty($this->TRIGGER_PREFIX) && strpos($triggerName, $this->TRIGGER_PREFIX . '_') !== 0) {
|
||||||
if (!preg_match('/^OBJECT_LINK/', $triggerName) && !preg_match('/^PAYMENTONLINE_/', $triggerName)) { // We add this exception as we have some call_trigger with a triggeName that is not the business object (as in method inside the commonobjet.class.php to manage links)
|
if (!preg_match('/^OBJECT_LINK/', $triggerName) && !preg_match('/^PAYMENTONLINE_/', $triggerName)) { // We add this exception as we have some call_trigger with a triggeName that is not the business object (as in method inside the commonobjet.class.php to manage links)
|
||||||
dol_print_error(null, 'The trigger "' . $triggerName . '" does not start with "' . $this->TRIGGER_PREFIX . '_" as required.');
|
dol_syslog('The trigger "' . $triggerName . '" does not start with "' . $this->TRIGGER_PREFIX . '_" as required.', LOG_ERROR);
|
||||||
exit;
|
//dol_print_error(null, 'The trigger "' . $triggerName . '" does not start with "' . $this->TRIGGER_PREFIX . '_" as required.');
|
||||||
|
//exit;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!is_object($langs)) { // If lang was not defined, we set it. It is required by run_triggers().
|
if (!is_object($langs)) { // If lang was not defined, we set it. It is required by run_triggers().
|
||||||
|
|||||||
Reference in New Issue
Block a user