}
/**
- * {@inheritdoc}
+ * @inheritDoc
*/
public function tryStashFile( User $user, $isPartial = false ) {
try {
}
/**
- * {@inheritdoc}
+ * @inheritDoc
* @throws UploadChunkVerificationException
* @deprecated since 1.28 Use tryStashFile() instead
*/
}
/**
- * {@inheritdoc}
+ * @inheritDoc
* @throws UploadChunkVerificationException
* @deprecated since 1.28
*/
}
/**
- * {@inheritdoc}
+ * @inheritDoc
* @throws UploadChunkVerificationException
* @deprecated since 1.28
*/
/**
* Append the final chunk and ready file for parent::performUpload()
- * @return FileRepoStatus
+ * @return Status
*/
public function concatenateChunks() {
$chunkIndex = $this->getChunkIndex();
// override doStashFile() with completely different functionality in this class...
$error = $this->runUploadStashFileHook( $this->user );
if ( $error ) {
- call_user_func_array( [ $status, 'fatal' ], $error );
+ $status->fatal( ...$error );
return $status;
}
try {
*
* @param string $chunkPath
* @throws UploadChunkFileException
- * @return FileRepoStatus
+ * @return Status
*/
private function outputChunk( $chunkPath ) {
// Key is fileKey + chunk index
class UploadChunkVerificationException extends MWException {
public $msg;
- public function __construct( $res ) {
- $this->msg = call_user_func_array( 'wfMessage', $res );
- parent::__construct( call_user_func_array( 'wfMessage', $res )
+ public function __construct( array $res ) {
+ $this->msg = wfMessage( ...$res );
+ parent::__construct( wfMessage( ...$res )
->inLanguage( 'en' )->useDatabase( false )->text() );
}
}