From 6f54db34059c99868c1457ce7654515f03bc9708 Mon Sep 17 00:00:00 2001 From: ZiRo Dev <31284099+Clientik@users.noreply.github.com> Date: Tue, 18 Jun 2019 20:42:22 +0300 Subject: [PATCH] fix Jest error An error occurred while testing via Jest "TypeError: Function has non-object prototype 'undefined' in instanceof check". Because of this error, the test results were incorrect. --- src/.internal/core/Sprite.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/.internal/core/Sprite.ts b/src/.internal/core/Sprite.ts index 73f357b01..20a87fea4 100644 --- a/src/.internal/core/Sprite.ts +++ b/src/.internal/core/Sprite.ts @@ -7288,7 +7288,7 @@ export class Sprite extends BaseObjectEvents implements IAnimatable { protected setPath(value: string): boolean { if (this.setPropertyValue("path", value)) { - if (!this.element || !(this.element instanceof SVGPathElement)) { + if (!this.element) { this.element = this.paper.add("path"); } this.element.attr({ "d": value });