bizproc :: DoUninstall: Bitrix method

      
<?php 
//  bizproc :: DoUninstall()
//  /dist/bitrix/modules/bizproc/install/index.php:186

    
function DoUninstall()
    {
        global 
$APPLICATION$step;

        
$this->errors = array();

        
$step IntVal($step);
        if(
$step<2)
        {
            if (
IsModuleInstalled("bizprocdesigner"))
                
$this->errors[] = Loc::getMessage("BIZPROC_BIZPROCDESIGNER_INSTALLED");

            
$GLOBALS["bizproc_installer_errors"] = $this->errors;
            
$APPLICATION->IncludeAdminFile(Loc::getMessage("BIZPROC_INSTALL_TITLE"), $_SERVER["DOCUMENT_ROOT"]."/bitrix/modules/bizproc/install/unstep1.php");
        }
        elseif(
$step==2)
        {
            
$this->UnInstallDB(array(
                
"savedata" => $_REQUEST["savedata"],
            ));
            
$this->UnInstallFiles();

            
$this->UnInstallEvents();

            
$GLOBALS["bizproc_installer_errors"] = $this->errors;
            
$APPLICATION->IncludeAdminFile(Loc::getMessage("BIZPROC_INSTALL_TITLE"), $_SERVER["DOCUMENT_ROOT"]."/bitrix/modules/bizproc/install/unstep2.php");
        }
    }