Last active
October 28, 2019 21:27
-
-
Save donpdonp/ad76f9377988bdc7bb484cc0ca580e06 to your computer and use it in GitHub Desktop.
gluon inline public
This file contains hidden or 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
(function() { | |
// descriptor | |
return {name:"inline-public"} | |
}) | |
function go(msg){ | |
if(msg.method == "irc.privmsg") { | |
if(msg.params.nick != bot.owner) { | |
var match = /(.*){{(.*)}}(.*)/.exec(msg.params.message) | |
if(match){ | |
return match[1]+JSON.stringify(eval(match[2]))+match[3] | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment