code: function objectToLowercase(obj) {
    var result = {};
    for (var key in obj) {
      if (obj.hasOwnProperty(key)) {
        result[key.toLowerCase()] = obj[key];
      }
    }
    return result;
  }
docs: This is copied directly from Cesium's WebMapServiceImageryProvider.