repositories
/
e-mobility-charging-stations-simulator.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix a null or undefined condition
[e-mobility-charging-stations-simulator.git]
/
src
/
utils
/
CircularArray.ts
diff --git
a/src/utils/CircularArray.ts
b/src/utils/CircularArray.ts
index d4e965e7adf22bdc5c571b3701db9541a7631c23..5fdeeaad1f7e57c2dae60d0c6fe976d623c942bd 100644
(file)
--- a/
src/utils/CircularArray.ts
+++ b/
src/utils/CircularArray.ts
@@
-47,7
+47,7
@@
export class CircularArray<T> extends Array<T> {
public splice(start: number, deleteCount?: number, ...items: T[]): T[] {
let itemsRemoved: T[];
public splice(start: number, deleteCount?: number, ...items: T[]): T[] {
let itemsRemoved: T[];
- if (arguments.length >= 3 &&
typeof deleteCount !== 'undefined'
) {
+ if (arguments.length >= 3 &&
deleteCount !== undefined
) {
itemsRemoved = super.splice(start, deleteCount);
// FIXME: that makes the items insert not in place
this.push(...items);
itemsRemoved = super.splice(start, deleteCount);
// FIXME: that makes the items insert not in place
this.push(...items);