UltrasonicNXT has submitted this change and it was merged. Change subject: Prevent the sending of purely-whitespace messages ......................................................................
Prevent the sending of purely-whitespace messages Brickimedia/brickimedia#214 Change-Id: Ib3992b26a1341e5c6fc19c4a08b80d7652bb1964 --- M MediaWikiChat.php M Send.api.php 2 files changed, 3 insertions(+), 1 deletion(-) Approvals: UltrasonicNXT: Verified; Looks good to me, approved diff --git a/MediaWikiChat.php b/MediaWikiChat.php index 6b1adb0..d575ceb 100644 --- a/MediaWikiChat.php +++ b/MediaWikiChat.php @@ -17,7 +17,7 @@ $wgExtensionCredits['specialpage'][] = array( 'path' => __FILE__, 'name' => 'MediaWikiChat', - 'version' => '2.5.3', + 'version' => '2.5.4', 'author' => 'Adam Carter/UltrasonicNXT', 'url' => 'https://www.mediawiki.org/wiki/Extension:MediaWikiChat', 'descriptionmsg' => 'chat-desc', diff --git a/Send.api.php b/Send.api.php index 56b5c13..e415aad 100644 --- a/Send.api.php +++ b/Send.api.php @@ -9,6 +9,8 @@ $message = $this->getMain()->getVal( 'message' ); if ( $wgUser->isAllowed( 'chat' ) ) { + $message = trim( $message ); + if ( $message != '' ) { $dbw = wfGetDB( DB_MASTER ); -- To view, visit https://gerrit.wikimedia.org/r/113372 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ib3992b26a1341e5c6fc19c4a08b80d7652bb1964 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/MediaWikiChat Gerrit-Branch: master Gerrit-Owner: UltrasonicNXT <adamr_car...@btinternet.com> Gerrit-Reviewer: UltrasonicNXT <adamr_car...@btinternet.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits