diff --git a/leaflet-iiif.js b/leaflet-iiif.js index 56bff60..ff90712 100644 --- a/leaflet-iiif.js +++ b/leaflet-iiif.js @@ -13,6 +13,8 @@ L.TileLayer.Iiif = L.TileLayer.extend({ }, initialize: function(url, options) { + options = typeof options !== 'undefined' ? options : {}; + if (options.maxZoom) { this._customMaxZoom = true; }