(key: unknown, item: unknown)
| 153 | |
| 154 | export class InvalidKeyError extends CollectionOperationError { |
| 155 | constructor(key: unknown, item: unknown) { |
| 156 | const keyType = key === null ? `null` : typeof key |
| 157 | super( |
| 158 | `getKey returned an invalid key type. Expected string or number, but got ${keyType}: ${JSON.stringify(key)}. Item: ${JSON.stringify(item)}`, |
| 159 | ) |
| 160 | } |
| 161 | } |
| 162 | |
| 163 | export class DuplicateKeyError extends CollectionOperationError { |
nothing calls this directly
no outgoing calls
no test coverage detected