From db4b0db9d204f75f701675e6f4922f3b23bbead0 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Wed, 14 Jan 2009 01:45:52 +0000 Subject: [PATCH] Added notifyRC2UDP() convenience function --- includes/RecentChange.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/includes/RecentChange.php b/includes/RecentChange.php index ac4de97d89..50b949c7cc 100644 --- a/includes/RecentChange.php +++ b/includes/RecentChange.php @@ -197,6 +197,14 @@ class RecentChange $this->mAttribs['rc_last_oldid'] ); } } + + public function notifyRC2UDP() { + global $wgRC2UDPAddress, $wgRC2UDPOmitBots; + # Notify external application via UDP + if( $wgRC2UDPAddress && ( !$this->mAttribs['rc_bot'] || !$wgRC2UDPOmitBots ) ) { + self::sendToUDP( $this->getIRCLine() ); + } + } /** * Send some text to UDP -- 2.20.1