23 public static function newJob(
31 'source' => $source->getPrefixedText(),
32 'target' => $target->getPrefixedText(),
35 'performer' => $performer->getName(),
38 return new self( $target, $params );
41 public function __construct( Title $title, array $params = [] ) {
42 parent::__construct(
'MoveTranslatableBundleJob', $title, $params );
43 $this->bundleMover = Services::getInstance()->getTranslatableBundleMover();
46 public function run() {
47 $sourceTitle = Title::newFromText( $this->params[
'source'] );
48 $targetTitle = Title::newFromText( $this->params[
'target'] );
50 $userFactory = MediaWikiServices::getInstance()->getUserFactory();
51 $performer = $userFactory->newFromName( $this->params[
'performer'] );
53 $this->bundleMover->moveSynchronously(
56 $this->params[
'moves'],
58 $this->params[
'summary']