mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 19:53:36 +00:00
Add user agent to request. Fix: 231
This commit is contained in:
parent
fc0a4d90df
commit
85151b23d3
@ -76,7 +76,8 @@ var Fetcher = function(url, reloadInterval, encoding) {
|
|||||||
scheduleTimer();
|
scheduleTimer();
|
||||||
});
|
});
|
||||||
|
|
||||||
request({uri: url, encoding: null}).pipe(iconv.decodeStream(encoding)).pipe(parser);
|
var headers = {'User-Agent':'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.75.14 (KHTML, like Gecko) Version/7.0.3 Safari/7046A194A'};
|
||||||
|
request({uri: url, encoding: null, headers: headers}).pipe(iconv.decodeStream(encoding)).pipe(parser);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user