Remove all remaining unnecessary casts

There is still such a cast in the goog library itself.
See https://github.com/google/closure-library/pull/637
This commit is contained in:
Guillaume Beraudo
2016-01-27 11:33:12 +01:00
parent 473cbba26e
commit 289e571fb0
11 changed files with 76 additions and 81 deletions
+3 -3
View File
@@ -98,13 +98,13 @@ ol.Feature = function(opt_geometryOrProperties) {
if (opt_geometryOrProperties !== undefined) {
if (opt_geometryOrProperties instanceof ol.geom.Geometry ||
!opt_geometryOrProperties) {
var geometry = /** @type {ol.geom.Geometry} */ (opt_geometryOrProperties);
var geometry = opt_geometryOrProperties;
this.setGeometry(geometry);
} else {
goog.asserts.assert(goog.isObject(opt_geometryOrProperties),
'opt_geometryOrProperties should be an Object');
var properties = /** @type {Object.<string, *>} */
(opt_geometryOrProperties);
/** @type {Object.<string, *>} */
var properties = opt_geometryOrProperties;
this.setProperties(properties);
}
}