Error disappears by updating any HTML element on the fusion gen page.

Source: https://perchance.org/fusion-ai-image-generator

Dynamic imports plugin: https://perchance.org/dynamic-import-plugin

I let name = localStorage.name , if it exists ,

when running dynamicImports(name).

I didn’t have this error when I implemented the localStorage thingy.

So I suspected this to be connected to some new added feature for dynamic Imports.

Ideas on solving this?

Code when I select names for dynamic import upon start (the error only occurs upon opening/reloading the page) :

_generator
    gen_danbooru
        fusion-t2i-danbooru-1
        fusion-t2i-danbooru-2
        fusion-t2i-danbooru-3

    gen_lyrics
        fusion-t2i-lyrics-1
        fusion-t2i-lyrics-2

...

_genKeys
    gen_danbooru
    gen_lyrics

...

// Initialize
getStartingValue(type) =>
  _genKeys.selectAll.forEach(function(_key) {
    document[_key] = 'fusion-t2i-empty';
    if (localStorage.getItem(_key) && localStorage.getItem(_key) != '' && localStorage.getItem(_key) != 'fusion-t2i-empty') {
      document[_key] = localStorage.getItem(_key);
    } else {
      document[_key] = [_generator[_key].selectOne];
      localStorage.setItem(_key, document[_key]);
    };
  });

...

  dynamicImport(document.gen_danbooru, 'preload');  

...

if (type == "danbooru"): return document.gen_danbooru; 
}; 

// End of getStartingValue(type)

...

_folders
  danbooru = dynamicImport(document.gen_danbooru || getStartingValue("danbooru"))