Skip to content

Commit

Permalink
Remove PHP4 constructors
Browse files Browse the repository at this point in the history
Signed-off-by: Dillon-Brown <[email protected]>
  • Loading branch information
Dillon-Brown authored and mattlorimer committed Mar 26, 2021
1 parent ee25525 commit 4ee7a70
Show file tree
Hide file tree
Showing 427 changed files with 904 additions and 5,795 deletions.
14 changes: 1 addition & 13 deletions ModuleInstall/ModuleInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,19 +78,7 @@ public function __construct()
$this->extensions = $extensions;
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ModuleInstaller()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



/*
Expand Down
14 changes: 1 addition & 13 deletions ModuleInstall/PackageManager/ListViewPackages.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,7 @@ public function __construct()
parent::__construct();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ListViewPackages()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



/**
Expand Down
15 changes: 0 additions & 15 deletions ModuleInstall/PackageManager/PackageController.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,21 +53,6 @@ public function __construct()
$this->_pm = new PackageManager();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function PackageController()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}


public function performBasicSearch()
{
$json = getJSONobj();
Expand Down
14 changes: 1 addition & 13 deletions ModuleInstall/PackageManager/PackageManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,19 +63,7 @@ public function __construct()
$this->upload_dir = empty($GLOBALS['sugar_config']['upload_dir']) ? 'upload' : rtrim($GLOBALS['sugar_config']['upload_dir'], '/\\');
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function PackageManager()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



public function initializeComm()
Expand Down
16 changes: 0 additions & 16 deletions XTemplate/xtpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,22 +156,6 @@ function __construct ($file, $alt_include = "", $mainblock="main") {
//$this->scan_globals();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
function XTemplate($file, $alt_include = "", $mainblock="main"){
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if(isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
}
else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($file, $alt_include, $mainblock);
}



/***************************************************************************/
/***[ public stuff ]********************************************************/
/***************************************************************************/
Expand Down
17 changes: 0 additions & 17 deletions data/SugarBean.php
Original file line number Diff line number Diff line change
Expand Up @@ -500,23 +500,6 @@ public function __construct()
$this->populateDefaultValues();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8,
* please update your code, use __construct instead
* @see SugarBean::__construct
*/
public function SugarBean()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, ' .
'please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}

/**
* Loads the definition of custom fields defined for the module.
* Local file system cache is created as needed.
Expand Down
15 changes: 0 additions & 15 deletions include/Dashlets/Dashlet.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,21 +104,6 @@ public function __construct($id)
$this->id = $id;
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function Dashlet($id)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($id);
}


/**
* Returns the HTML for the configure icon
*
Expand Down
14 changes: 0 additions & 14 deletions include/Dashlets/DashletGeneric.php
Original file line number Diff line number Diff line change
Expand Up @@ -153,20 +153,6 @@ public function __construct($id, $options = null)
$this->lvs = new ListViewSmarty();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function DashletGeneric($id, $options = null)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($id, $options);
}

/**
* Sets up the display options template
*
Expand Down
14 changes: 1 addition & 13 deletions include/DetailView/DetailView.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,19 +62,7 @@ public function __construct()
$this->local_app_strings =$app_strings;
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function DetailView()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



public function processSugarBean($html_varName, $seed, $offset)
Expand Down
15 changes: 0 additions & 15 deletions include/EditView/EditView.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,21 +75,6 @@ public function __construct($module, $template)
$this->ss = new Sugar_Smarty();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function EditView($module, $template)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($module, $template);
}


/**
* Processes / setups the template
* assigns all things to the template like mod_srings and app_strings
Expand Down
15 changes: 0 additions & 15 deletions include/EditView/PopupQuickCreate.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,21 +55,6 @@ public function __construct($module, $view='QuickCreate')
$this->ev->defs['templateMeta']['form']['buttons'] = array('POPUPSAVE', 'POPUPCANCEL');
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function PopupQuickCreate($module, $view='QuickCreate')
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($module, $view);
}


public function process($module)
{
$form_name = 'form_QuickCreate_' . $module;
Expand Down
14 changes: 0 additions & 14 deletions include/EditView/SubpanelQuickCreate.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,20 +158,6 @@ public function __construct($module, $view='QuickCreate', $proccessOverride = fa
}
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function SubpanelQuickCreate($module, $view='QuickCreate', $proccessOverride = false)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($module, $view, $proccessOverride);
}

public function process($module)
{
if ($_REQUEST['target_action'] == 'QuickCreate') {
Expand Down
14 changes: 0 additions & 14 deletions include/EditView/SubpanelQuickEdit.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,20 +148,6 @@ public function __construct($module, $view='QuickEdit', $proccessOverride = fals
}
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function SubpanelQuickEdit($module, $view='QuickEdit', $proccessOverride = false)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($module, $view, $proccessOverride);
}

public function process($module)
{
$form_name = 'form_Subpanel'.$this->ev->view .'_'.$module;
Expand Down
14 changes: 1 addition & 13 deletions include/ListView/ListViewData.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,19 +73,7 @@ public function __construct()
$this->db = DBManagerFactory::getInstance('listviews');
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ListViewData()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



/**
Expand Down
14 changes: 1 addition & 13 deletions include/ListView/ListViewDisplay.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,19 +84,7 @@ public function __construct()
$this->searchColumns = array() ;
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ListViewDisplay()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



public function shouldProcess($moduleDir)
Expand Down
14 changes: 0 additions & 14 deletions include/ListView/ListViewFacade.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,20 +88,6 @@ public function __construct($focus, $module, $type = 0)
$this->build();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ListViewFacade($focus, $module, $type = 0)
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct($focus, $module, $type);
}

/**
* Retrieves display columns on list view of specified module
*
Expand Down
14 changes: 1 addition & 13 deletions include/ListView/ListViewXTPL.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,19 +62,7 @@ public function __construct()
parent::__construct();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function ListViewXTPL()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}



/**
Expand Down
14 changes: 1 addition & 13 deletions include/Localization/Localization.php
Original file line number Diff line number Diff line change
Expand Up @@ -101,19 +101,7 @@ public function __construct()
$this->loadCurrencies();
}

/**
* @deprecated deprecated since version 7.6, PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code, use __construct instead
*/
public function Localization()
{
$deprecatedMessage = 'PHP4 Style Constructors are deprecated and will be remove in 7.8, please update your code';
if (isset($GLOBALS['log'])) {
$GLOBALS['log']->deprecated($deprecatedMessage);
} else {
trigger_error($deprecatedMessage, E_USER_DEPRECATED);
}
self::__construct();
}


/**
* returns an array of Sugar Config defaults that are determined by locale settings
Expand Down
Loading

0 comments on commit 4ee7a70

Please sign in to comment.