forked from GitHub/dbot
give reasonable size limit [#332]
This commit is contained in:
parent
6176dd5695
commit
e9b4a9f112
@ -11,7 +11,7 @@ var link = function(dbot) {
|
|||||||
this.urlRegex = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig;
|
this.urlRegex = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig;
|
||||||
this.links = {};
|
this.links = {};
|
||||||
this.fetchTitle = function(event, link) {
|
this.fetchTitle = function(event, link) {
|
||||||
var limit = 25 * 1000,
|
var limit = 250 * 1000,
|
||||||
size = 0,
|
size = 0,
|
||||||
page = request(link, function(error, response, body) {
|
page = request(link, function(error, response, body) {
|
||||||
if(!error && response.statusCode == 200) {
|
if(!error && response.statusCode == 200) {
|
||||||
|
Loading…
Reference in New Issue
Block a user