Fix URLs in /index.json and /rendered.json
This commit is contained in:
parent
2d29a21596
commit
557f83121c
1 changed files with 7 additions and 2 deletions
|
@ -175,8 +175,13 @@ module.exports = function(opts, callback) {
|
||||||
var addTileJSONs = function(arr, req, type) {
|
var addTileJSONs = function(arr, req, type) {
|
||||||
Object.keys(serving[type]).forEach(function(id) {
|
Object.keys(serving[type]).forEach(function(id) {
|
||||||
var info = clone(serving[type][id]);
|
var info = clone(serving[type][id]);
|
||||||
info.tiles = utils.getTileUrls(req, info.tiles,
|
var path = '';
|
||||||
type + '/' + id, info.format);
|
if (type == 'rendered') {
|
||||||
|
path = 'styles/' + id + '/rendered';
|
||||||
|
} else {
|
||||||
|
path = type + '/' + id;
|
||||||
|
}
|
||||||
|
info.tiles = utils.getTileUrls(req, info.tiles, path, info.format);
|
||||||
arr.push(info);
|
arr.push(info);
|
||||||
});
|
});
|
||||||
return arr;
|
return arr;
|
||||||
|
|
Loading…
Reference in a new issue