From 57cfe50ec7df6ba532fb72adcea9ce65374c117e Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Tue, 27 Aug 2013 17:28:28 -0700 Subject: [PATCH] Support {-y} notation --- js/id/renderer/background_source.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/id/renderer/background_source.js b/js/id/renderer/background_source.js index 2e9c23025..b8041a2d3 100644 --- a/js/id/renderer/background_source.js +++ b/js/id/renderer/background_source.js @@ -21,7 +21,7 @@ iD.BackgroundSource = function(data) { .replace('{x}', coord[0]) .replace('{y}', coord[1]) // TMS-flipped y coordinate - .replace('{ty}', Math.pow(2, coord[2]) - coord[1] - 1) + .replace(/\{[t-]y\}/, Math.pow(2, coord[2]) - coord[1] - 1) .replace(/\{z(oom)?\}/, coord[2]) .replace(/\{switch:([^}]+)\}/, function(s, r) { var subdomains = r.split(',');