3
0
mirror of https://github.com/reality/dbot.git synced 2024-11-23 20:39:25 +01:00

Change sep. char to comma for YT merge [Close #589]

This commit is contained in:
reality 2013-10-08 13:08:57 +00:00
parent b6d7a92b32
commit bf0c277ad6

View File

@ -43,7 +43,7 @@ var youtube = function(dbot) {
var link = v.link[0].href.match(this.LinkRegex)[2]; var link = v.link[0].href.match(this.LinkRegex)[2];
event.reply(dbot.t('yt_video', { event.reply(dbot.t('yt_video', {
'title': v.title['$t'], 'title': v.title['$t'],
'plays': v['yt$statistics'].viewCount.toString().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1 "), 'plays': v['yt$statistics'].viewCount.toString().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,"),
'author': v.author[0].name['$t'], 'author': v.author[0].name['$t'],
'likes': v['yt$rating'].numLikes, 'likes': v['yt$rating'].numLikes,
'dislikes': v['yt$rating'].numDislikes, 'dislikes': v['yt$rating'].numDislikes,
@ -84,7 +84,7 @@ var youtube = function(dbot) {
callback(dbot.t('yt_video', { callback(dbot.t('yt_video', {
'title': v.title['$t'], 'title': v.title['$t'],
'plays': v['yt$statistics'].viewCount.toString().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1 "), 'plays': v['yt$statistics'].viewCount.toString().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,"),
'author': v.author[0].name['$t'], 'author': v.author[0].name['$t'],
'likes': v['yt$rating'].numLikes, 'likes': v['yt$rating'].numLikes,
'dislikes': v['yt$rating'].numDislikes, 'dislikes': v['yt$rating'].numDislikes,