More sensible semantics for pipe trick with section links after r62076
[lhc/web/wiklou.git] / maintenance / patchSql.php
index 18835a4..6071323 100644 (file)
@@ -27,7 +27,7 @@ class PatchSql extends Maintenance {
        public function __construct() {
                parent::__construct();
                $this->mDescription = "Run an SQL file into the DB, replacing prefix and charset vars";
-               $this->addArgs( array( 'patch-name' ) );
+               $this->addArg( 'patch-name', 'Name of the patch file, either full path or in maintenance/archives' );
        }
 
        protected function getDbType() {
@@ -39,8 +39,8 @@ class PatchSql extends Maintenance {
                foreach( $this->mArgs as $arg ) {
                        $files = array(
                                $arg,
-                               DatabaseBase::patchPatch( $arg ),
-                               DatabaseBase::patchPatch( "patch-$arg.sql" ),
+                               DatabaseBase::patchPath( $arg ),
+                               DatabaseBase::patchPath( "patch-$arg.sql" ),
                        );
                        foreach( $files as $file ) {
                                if( file_exists( $file ) ) {