$noOldArchive = ""; // yes this really needs to be set this way
$comment = "removing for test";
$restrictDeletedVersions = false;
- $status = FileDeleteForm::doDelete( $title, $file, $noOldArchive, $comment, $restrictDeletedVersions );
+ $status = FileDeleteForm::doDelete(
+ $title,
+ $file,
+ $noOldArchive,
+ $comment,
+ $restrictDeletedVersions
+ );
+
if ( !$status->isGood() ) {
return false;
}
+
$page = WikiPage::factory( $title );
$page->doDeleteArticle( "removing for test" );
}
/**
- * Helper function -- given a file on the filesystem, find matching content in the db (and associated articles) and remove them.
+ * Helper function -- given a file on the filesystem, find matching
+ * content in the db (and associated articles) and remove them.
*
* @param string $filePath path to file on the filesystem
*
*
* @param string $fieldName name this would have in the upload form
* @param string $fileName name to title this
- * @param string $type mime type
+ * @param string $type MIME type
* @param string $filePath path where to find file contents
*
* @throws Exception