Created
April 3, 2015 01:16
-
-
Save Buildstarted/cee03bce7926f5006c79 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name JabbR Firehose | |
// @namespace http://jabbr.buildstarted.com/ | |
// @version 0.1 | |
// @description firehose | |
// @match https://jabbr.net/* | |
// @copyright 2012+, You | |
// @require http://code.jquery.com/jquery-latest.js | |
// ==/UserScript== | |
var origChatMessageHandler = unsafeWindow.chat.ui.addChatMessage; | |
unsafeWindow.chat.ui.addChatMessage = function (message, roomName) { | |
origChatMessageHandler.apply(this, [message, roomName]); | |
try { | |
message.message = "<a href='#/rooms/" + roomName + "'>#" + roomName + "</a>: " + message.message; | |
origChatMessageHandler.apply(this, [message, 'firehose']); | |
} catch (e) { } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment