mirror of
https://github.com/reality/dbot.git
synced 2024-11-30 16:09:27 +01:00
change ~film to ~imdb
This commit is contained in:
parent
3dfa3be2e1
commit
439d25f9b0
@ -31,7 +31,7 @@ var imdb = function(dbot) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
this.commands = {
|
this.commands = {
|
||||||
'~film': function(event) {
|
'~imdb': function(event) {
|
||||||
request.get(ApiRoot, {
|
request.get(ApiRoot, {
|
||||||
'qs': {
|
'qs': {
|
||||||
'q': event.input[1],
|
'q': event.input[1],
|
||||||
@ -47,7 +47,7 @@ var imdb = function(dbot) {
|
|||||||
}.bind(this));
|
}.bind(this));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
this.commands['~film'].regex = [/^~film (.+)$/, 2];
|
this.commands['~imdb'].regex = [/^~film (.+)$/, 2];
|
||||||
|
|
||||||
this.onLoad = function() {
|
this.onLoad = function() {
|
||||||
dbot.api.link.addHandler('imdb', /https?:\/\/(www\.)?imdb\.com\/title\/([a-zA-Z0-9]+)/, function(matches, name, callback) {
|
dbot.api.link.addHandler('imdb', /https?:\/\/(www\.)?imdb\.com\/title\/([a-zA-Z0-9]+)/, function(matches, name, callback) {
|
||||||
|
Loading…
Reference in New Issue
Block a user