Fix scrutinizer bugs
This commit is contained in:
parent
6f95a7c2b1
commit
5a397fff72
@ -505,7 +505,7 @@ class Account extends CommonObject
|
||||
* @param int $notrigger 1=Disable triggers
|
||||
* @return int < 0 if KO, > 0 if OK
|
||||
*/
|
||||
function create(User $user = null, $notrigger=0)
|
||||
function create(User $user, $notrigger=0)
|
||||
{
|
||||
global $langs,$conf, $hookmanager;
|
||||
|
||||
|
||||
@ -263,7 +263,7 @@ class DolibarrModules // Can not be abstract, because we need to insta
|
||||
public $always_enabled;
|
||||
|
||||
/**
|
||||
* @var bool Module is enabled globally (Multicompany support)
|
||||
* @var int Module is enabled globally (Multicompany support)
|
||||
*/
|
||||
public $core_enabled;
|
||||
|
||||
|
||||
@ -52,7 +52,7 @@ class modSyslog extends DolibarrModules
|
||||
// Module description, used if translation string 'ModuleXXXDesc' not found (where XXX is value of numeric property 'numero' of module)
|
||||
$this->description = "Activate debug logs (syslog)";
|
||||
// Can be enabled / disabled only in the main company
|
||||
$this->core_enabled = true;
|
||||
$this->core_enabled = 1;
|
||||
// Possible values for version are: 'development', 'experimental', 'dolibarr' or version
|
||||
$this->version = 'dolibarr';
|
||||
// Key used in llx_const table to save module status enabled/disabled (where MYMODULE is value of property name of module in uppercase)
|
||||
|
||||
@ -624,8 +624,9 @@ if (empty($reshook))
|
||||
$card=$cu->sources->retrieve("$source");
|
||||
if ($card)
|
||||
{
|
||||
$card->delete();
|
||||
// $card->detach(); Does not work with card_, only with src_
|
||||
if (method_exists($card, 'detach')) $card->detach();
|
||||
else $card->delete();
|
||||
}
|
||||
|
||||
$url=DOL_URL_ROOT.'/societe/paymentmodes.php?socid='.$object->id;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user