mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-24 07:54:13 +00:00
cdae062d47
Change-Id: I44f872b3a2921e75aab8e22fec57735f17ee1d8b
20 lines
448 B
PHP
20 lines
448 B
PHP
<?php
|
|
|
|
class EchoNotificationJob extends Job {
|
|
/** @var int */
|
|
private $eventId;
|
|
|
|
public function __construct( $title, $params ) {
|
|
parent::__construct( 'EchoNotificationJob', $title, $params );
|
|
$this->eventId = $params['eventId'];
|
|
}
|
|
|
|
public function run() {
|
|
MWEchoDbFactory::newFromDefault()->waitForSlaves();
|
|
$event = EchoEvent::newFromID( $this->eventId );
|
|
EchoNotificationController::notify( $event, false );
|
|
|
|
return true;
|
|
}
|
|
}
|