diff --git a/src/objectliterals.jsdoc b/src/objectliterals.jsdoc index ade707fd70..e26100a3b2 100644 --- a/src/objectliterals.jsdoc +++ b/src/objectliterals.jsdoc @@ -697,7 +697,7 @@ * function to load a tile given a URL. * @property {string|undefined} url URL template. Must include `{x}`, `{y}`, * and `{z}` placeholders. Default is - * `http://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png`. + * `//{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png`. * @todo stability experimental */ diff --git a/src/ol/source/osmsource.js b/src/ol/source/osmsource.js index 84175b5666..4fe96661d3 100644 --- a/src/ol/source/osmsource.js +++ b/src/ol/source/osmsource.js @@ -26,7 +26,7 @@ ol.source.OSM = function(opt_options) { options.crossOrigin : 'anonymous'; var url = goog.isDef(options.url) ? - options.url : 'http://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png'; + options.url : '//{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png'; goog.base(this, { attributions: attributions,