From 664759c9c0fa5ec45bbc70132aa48c17c024af23 Mon Sep 17 00:00:00 2001 From: Hugh Anderson Date: Thu, 19 Dec 2019 10:23:21 -0500 Subject: [PATCH] Fix crash when re-instantiating particles after destroy --- particles.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/particles.js b/particles.js index 325d8349..dba69d90 100644 --- a/particles.js +++ b/particles.js @@ -1236,7 +1236,7 @@ var pJS = function(tag_id, params){ pJS.fn.vendors.destroypJS = function(){ cancelAnimationFrame(pJS.fn.drawAnimFrame); canvas_el.remove(); - pJSDom = null; + pJSDom = []; }; @@ -1538,4 +1538,4 @@ window.particlesJS.load = function(tag_id, path_config_json, callback){ }; xhr.send(); -}; \ No newline at end of file +};