if( is_file( $this->mSavedFile ) ) {
$this->mUploadOldVersion = gmdate( 'YmdHis' ) . "!{$saveName}";
- if( !rename( $this->mSavedFile, "${archive}/{$this->mUploadOldVersion}" ) ) {
+ if( @!rename( $this->mSavedFile, "${archive}/{$this->mUploadOldVersion}" ) ) {
$wgOut->fileRenameError( $this->mSavedFile,
"${archive}/{$this->mUploadOldVersion}" );
return false;
}
if( $useRename ) {
- if( !rename( $tempName, $this->mSavedFile ) ) {
+ if( @!rename( $tempName, $this->mSavedFile ) ) {
$wgOut->fileCopyError( $tempName, $this->mSavedFile );
return false;
}
} else {
- if( !move_uploaded_file( $tempName, $this->mSavedFile ) ) {
+ if( @!move_uploaded_file( $tempName, $this->mSavedFile ) ) {
$wgOut->fileCopyError( $tempName, $this->mSavedFile );
return false;
}
* @access private
*/
function saveTempUploadedFile( $saveName, $tempName ) {
- global $wgOut;
-
+ global $wgOut;
$archive = wfImageArchiveDir( $saveName, 'temp' );
$stash = $archive . '/' . gmdate( "YmdHis" ) . '!' . $saveName;
* @return int
* @access private
*/
- function stashSession() {
+ function stashSession() {
$stash = $this->saveTempUploadedFile(
$this->mUploadSaveName, $this->mUploadTempName );