Fix phpcs

This commit is contained in:
Laurent Destailleur 2020-11-26 08:40:08 +01:00
parent cdb3350259
commit e272130a6a
3 changed files with 8 additions and 9 deletions

View File

@ -630,7 +630,7 @@ else $buttonLabel = $langs->trans("ExportList");
$parameters = array();
$reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
if (empty($reshook)) {
// Button re-export
// Button re-export
if (!empty($conf->global->ACCOUNTING_REEXPORT)) {
$newcardbutton = '<a class="valignmiddle" href="' . $_SERVER['PHP_SELF'] . '?action=setreexport&token=' . newToken() . '&value=0' . ($param ? '&' . $param : '') . '">' . img_picto($langs->trans("Activated"), 'switch_on') . '</a> ';
} else {

View File

@ -8512,13 +8512,13 @@ abstract class CommonObject
}
$sql = 'DELETE FROM '.MAIN_DB_PREFIX."ecm_files";
$sql .= " WHERE src_object_type = '".$this->db->escape($this->table_element.(empty($this->module) ? '' : '@'.$this->module))."' AND src_object_id = ".$this->id;
$resql = $this->db->query($sql);
if (!$resql) {
$this->error = $this->db->lasterror();
$this->db->rollback();
return false;
}
$sql .= " WHERE src_object_type = '".$this->db->escape($this->table_element.(empty($this->module) ? '' : '@'.$this->module))."' AND src_object_id = ".$this->id;
$resql = $this->db->query($sql);
if (!$resql) {
$this->error = $this->db->lasterror();
$this->db->rollback();
return false;
}
}
$this->db->commit();

View File

@ -163,4 +163,3 @@ function dolSessionGC($max_lifetime)
// Call to register user call back functions.
session_set_save_handler("dolSessionOpen", "dolSessionClose", "dolSessionRead", "dolSessionWrite", "dolSessionDestroy", "dolSessionGC");