don't overwrite default options if not specified (faster construction)

This commit is contained in:
Vladimir Agafonkin 2013-12-04 17:38:55 +02:00
parent 5bc104237e
commit 3a0b1bf1d5

View File

@ -107,7 +107,9 @@ L.Util = {
},
setOptions: function (obj, options) {
obj.options = L.extend({}, obj.options, options);
if (options) {
obj.options = L.extend({}, obj.options, options);
}
return obj.options;
},