UltrasonicNXT has submitted this change and it was merged. Change subject: Fix some users appearing twice in the user list ......................................................................
Fix some users appearing twice in the user list It seems this was not updated with the user object change, and I've also simplyfied the code slightly. Also, I've bumped the version up (should have been with the sidebar commit) Brickimedia/brickimedia#149 Change-Id: Ie5206199c7bac087c1233fb30aa426104a0ec749 --- M MediaWikiChat.js M MediaWikiChat.php 2 files changed, 5 insertions(+), 5 deletions(-) Approvals: UltrasonicNXT: Verified; Looks good to me, approved diff --git a/MediaWikiChat.js b/MediaWikiChat.js index e63ca96..38e4d75 100644 --- a/MediaWikiChat.js +++ b/MediaWikiChat.js @@ -366,11 +366,11 @@ var add = true; - $.each( $( '#mwchat-users div' ), ( function( index, item ) { - if ( item.id == user.userE ) { - add = false; + $( '#mwchat-users div' ).each( function( index ) { + if ( $( this ).attr( 'data-id' ) == user.id ) { + add = false; + } } - }) ); if ( add ) { diff --git a/MediaWikiChat.php b/MediaWikiChat.php index 7caa320..773c8d7 100644 --- a/MediaWikiChat.php +++ b/MediaWikiChat.php @@ -17,7 +17,7 @@ $wgExtensionCredits['specialpage'][] = array( 'path' => __FILE__, 'name' => 'MediaWikiChat', - 'version' => '2.1', + 'version' => '2.2', 'author' => 'Adam Carter/UltrasonicNXT', 'url' => 'https://www.mediawiki.org/wiki/Extension:MediaWikiChat', 'descriptionmsg' => 'chat-desc', -- To view, visit https://gerrit.wikimedia.org/r/104756 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: Ie5206199c7bac087c1233fb30aa426104a0ec749 Gerrit-PatchSet: 3 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