remove debugging. note: offload timers to appropriate clllllosure

This commit is contained in:
reality 2013-12-22 04:09:37 +00:00
parent 148535e7de
commit fe0cbf048b

View File

@ -97,7 +97,6 @@ var reddit = function(dbot) {
}, },
'getPostInfo': function(name, callback) { 'getPostInfo': function(name, callback) {
console.log('MAKIN A REQUEST');
request.get({ request.get({
'url': this.ApiRoot + 'comments/' + name + '.json', 'url': this.ApiRoot + 'comments/' + name + '.json',
'json': true, 'json': true,
@ -129,7 +128,6 @@ var reddit = function(dbot) {
}, },
'getNewPosts': function(sr, last, callback) { 'getNewPosts': function(sr, last, callback) {
console.log('MAKIN A REQUEST');
request.get({ request.get({
'url': this.ApiRoot + 'r/' + sr + '/new.json', 'url': this.ApiRoot + 'r/' + sr + '/new.json',
'json': true, 'json': true,
@ -209,7 +207,6 @@ var reddit = function(dbot) {
this.commands['~rmredditfeed'].access = 'moderator'; this.commands['~rmredditfeed'].access = 'moderator';
this.onDestroy = function() { this.onDestroy = function() {
console.log('call de ondestroy');
for(i=0;i<this.ints.length;i++) { for(i=0;i<this.ints.length;i++) {
clearInterval(this.ints[i]); clearInterval(this.ints[i]);
} }
@ -219,7 +216,6 @@ var reddit = function(dbot) {
this.internalAPI.reloadChannelFeeds(); this.internalAPI.reloadChannelFeeds();
var rHandler = function(matches, name, callback) { var rHandler = function(matches, name, callback) {
console.log('reddit is handling the link');
if(matches[6]) { // It's a comment if(matches[6]) { // It's a comment
this.api.getCommentInfo(matches[4], matches[6], function(info) { this.api.getCommentInfo(matches[4], matches[6], function(info) {
if(info) { if(info) {
@ -236,9 +232,7 @@ var reddit = function(dbot) {
} }
}); });
} else if(matches[4]) { // It's a post } else if(matches[4]) { // It's a post
console.log('it is a post');
this.api.getPostInfo(matches[4], function(info) { this.api.getPostInfo(matches[4], function(info) {
console.log('got post info');
if(info) { if(info) {
var infoString = dbot.t('about_post', { var infoString = dbot.t('about_post', {
'title': info.title.trim(), 'title': info.title.trim(),