mirror of
https://github.com/reality/dbot.git
synced 2024-11-30 16:09:27 +01:00
you fool you foolish fool
This commit is contained in:
parent
0697f0b5a0
commit
1af4788de0
@ -168,7 +168,7 @@ var reddit = function(dbot) {
|
|||||||
'~question': function(event) {
|
'~question': function(event) {
|
||||||
this.api.getTopPosts('askreddit', function(err, posts) {
|
this.api.getTopPosts('askreddit', function(err, posts) {
|
||||||
if(!err) {
|
if(!err) {
|
||||||
var qPost = _.random(0, posts.length - 1);
|
var qPost = posts[_.random(0, posts.length - 1)];
|
||||||
event.reply('Question: ' + qPost.title.trim());
|
event.reply('Question: ' + qPost.title.trim());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user