Skip to content

Commit

Permalink
fix(data): allow ChangeSetItemFactory to update entities with number ids
Browse files Browse the repository at this point in the history
Allow the `update` method of ChangeSetItemFactory to accept entities with numerical IDs.
This seems to be the intent, as the `Update<T>` it accepts can use either a string or a number for the ID, while the `update` method only allows for string IDs

Closes #1988
  • Loading branch information
allout58 committed Jul 3, 2019
1 parent 2b8178d commit 797391d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/data/src/actions/entity-cache-change-set.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ export class ChangeSetItemFactory {
}

/** Create the ChangeSetUpdate for Updates of entities of the given entity type */
update<T extends { id: string }>(
update<T extends { id: string | number }>(
entityName: string,
updates: Update<T> | Update<T>[]
): ChangeSetUpdate<T> {
Expand Down

0 comments on commit 797391d

Please sign in to comment.