fix(animations): allow players to be destroyed before initialized (#13346)
Closes #13293 Closes #13346
This commit is contained in:

committed by
Chuck Jazdzewski

parent
5b6e8ea3ec
commit
0c19898694
@ -124,7 +124,11 @@ export class WebAnimationsPlayer implements AnimationPlayer {
|
||||
this._started = false;
|
||||
}
|
||||
|
||||
private _resetDomPlayerState() { this._player.cancel(); }
|
||||
private _resetDomPlayerState() {
|
||||
if (this._player) {
|
||||
this._player.cancel();
|
||||
}
|
||||
}
|
||||
|
||||
restart(): void {
|
||||
this.reset();
|
||||
|
Reference in New Issue
Block a user