Skip to content

Commit

Permalink
Merge pull request #5791 from gberaudo/tentative_type_fix
Browse files Browse the repository at this point in the history
Use associative array key type for entity collection ids
  • Loading branch information
pjcozzi authored Sep 1, 2017
2 parents 2f7421b + 9e8c390 commit 5ac57c7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ Change Log
==========
### 1.37 - 2017-09-01

* Fixed `Entity` id type to be `String` in `EntityCollection` and `CompositeEntityCollection` [#5791](https://github.com/AnalyticalGraphicsInc/cesium/pull/579)
* Fixed `replaceState` bug that was causing the `CesiumViewer` demo application to crash in Safari and iOS
* Fixed issue where `Model` and `BillboardCollection` would throw an error if the globe is undefined [#5638](https://github.com/AnalyticalGraphicsInc/cesium/issues/5638)
* Fixed issue where the `Model` glTF cache loses reference to the model's buffer data. [#5720](https://github.com/AnalyticalGraphicsInc/cesium/issues/5720)
Expand Down
2 changes: 1 addition & 1 deletion Source/DataSources/CompositeEntityCollection.js
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ define([
/**
* Gets an entity with the specified id.
*
* @param {Object} id The id of the entity to retrieve.
* @param {String} id The id of the entity to retrieve.
* @returns {Entity} The entity with the provided id or undefined if the id did not exist in the collection.
*/
CompositeEntityCollection.prototype.getById = function(id) {
Expand Down
6 changes: 3 additions & 3 deletions Source/DataSources/EntityCollection.js
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ define([
/**
* Removes an entity with the provided id from the collection.
*
* @param {Object} id The id of the entity to remove.
* @param {String} id The id of the entity to remove.
* @returns {Boolean} true if the item was removed, false if no item with the provided id existed in the collection.
*/
EntityCollection.prototype.removeById = function(id) {
Expand Down Expand Up @@ -382,7 +382,7 @@ define([
/**
* Gets an entity with the specified id.
*
* @param {Object} id The id of the entity to retrieve.
* @param {String} id The id of the entity to retrieve.
* @returns {Entity} The entity with the provided id or undefined if the id did not exist in the collection.
*/
EntityCollection.prototype.getById = function(id) {
Expand All @@ -398,7 +398,7 @@ define([
/**
* Gets an entity with the specified id or creates it and adds it to the collection if it does not exist.
*
* @param {Object} id The id of the entity to retrieve or create.
* @param {String} id The id of the entity to retrieve or create.
* @returns {Entity} The new or existing object.
*/
EntityCollection.prototype.getOrCreateEntity = function(id) {
Expand Down

0 comments on commit 5ac57c7

Please sign in to comment.