mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-12 09:26:05 +00:00
Merge "Fixing notification type to be 'web' in controller"
This commit is contained in:
commit
567e11bb14
|
@ -139,7 +139,7 @@ class EchoNotificationController {
|
|||
}
|
||||
|
||||
if ( $event->getType() == 'welcome' ) { // Welcome events should only be sent to the new user, no need for subscriptions.
|
||||
self::doNotification( $event, $event->getAgent(), 'notify' );
|
||||
self::doNotification( $event, $event->getAgent(), 'web' );
|
||||
} else {
|
||||
$subscriptions = self::getSubscriptionsForEvent( $event );
|
||||
|
||||
|
@ -235,11 +235,11 @@ class EchoNotificationController {
|
|||
* @param $event EchoEvent that the notification is for.
|
||||
* @param $user User to format the notification for.
|
||||
* @param $format string The format to show the notification in: text, html, or email
|
||||
* @param $type string The type of notification being distributed (e.g. email, notify)
|
||||
* @param $type string The type of notification being distributed (e.g. email, web)
|
||||
* @return string|array The formatted notification, or an array of subject
|
||||
* and body (for emails), or an error message
|
||||
*/
|
||||
public static function formatNotification( $event, $user, $format = 'text', $type = 'notify' ) {
|
||||
public static function formatNotification( $event, $user, $format = 'text', $type = 'web' ) {
|
||||
global $wgEchoNotificationFormatters;
|
||||
|
||||
$eventType = $event->getType();
|
||||
|
|
|
@ -97,7 +97,7 @@ class EchoBasicFormatter extends EchoNotificationFormatter {
|
|||
*
|
||||
* @param $event EchoEvent that the notification is for.
|
||||
* @param $user User to format the notification for.
|
||||
* @param $type string The type of notification being distributed (e.g. email, notify)
|
||||
* @param $type string The type of notification being distributed (e.g. email, web)
|
||||
* @return array|string
|
||||
*/
|
||||
public function format( $event, $user, $type ) {
|
||||
|
|
Loading…
Reference in a new issue