X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22articles%22%2C%22id_article=%24id_article%22%29%20.%20%22?a=blobdiff_plain;f=maintenance%2FpurgeOldText.php;h=e68047c00ddd415b0bed7e6e3126418b3af61d26;hb=392af46809d831514f49618cdef1e1529d7fddf4;hp=9e078b800b4bd8f55e60503d889769d0811f4117;hpb=a1c51e18af85a9ac464c5b555921e58ec422cd11;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/purgeOldText.php b/maintenance/purgeOldText.php index 9e078b800b..e68047c00d 100644 --- a/maintenance/purgeOldText.php +++ b/maintenance/purgeOldText.php @@ -17,23 +17,29 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * http://www.gnu.org/copyleft/gpl.html * + * @file * @ingroup Maintenance * @author Rob Church */ -require_once( "Maintenance.php" ); +require_once( dirname( __FILE__ ) . '/Maintenance.php' ); +/** + * Maintenance script that purges old text records from the database. + * + * @ingroup Maintenance + */ class PurgeOldText extends Maintenance { public function __construct() { parent::__construct(); $this->mDescription = "Purge old text records from the database"; $this->addOption( 'purge', 'Performs the deletion' ); } - + public function execute() { - $this->purgeRedundantText( $this->hasOption('purge') ); + $this->purgeRedundantText( $this->hasOption( 'purge' ) ); } } $maintClass = "PurgeOldText"; -require_once( DO_MAINTENANCE ); +require_once( RUN_MAINTENANCE_IF_MAIN );