Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

Commit 6e8d047

Browse files
wheelerlawwardbell
authored andcommitted
chore; let tslint allow double equals when comparing IDs of different types (#91)
1 parent 92bebf3 commit 6e8d047

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/in-memory-backend.service.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -651,7 +651,8 @@ export class InMemoryBackendService {
651651
if (item.id == undefined) {
652652
return createErrorResponse(req, STATUS.NOT_FOUND, `Missing '${collectionName}' id`);
653653
}
654-
if (id !== item.id) {
654+
// tslint:disable-next-line:triple-equals
655+
if (id != item.id) {
655656
return createErrorResponse(req, STATUS.BAD_REQUEST, `"${collectionName}" id does not match item.id`);
656657
}
657658
const existingIx = this.indexOf(collection, id);

0 commit comments

Comments
 (0)