In the preload function, the shared object ins't created yet.
Example:
async function preload(seneca) {
// seneca.shared is null
seneca.shared = {}; // Need to manually boot seneca shared
// Now you can use the seneca.shared instance here
seneca.shared.x = 10;
// shared.x will be available outside
}
Fix:
Instead of manually creating seneca.shared = {}, the seneca instance should be available already in preload function.
In the preload function, the shared object ins't created yet. Example:
Fix: Instead of manually creating
seneca.shared = {}
, the seneca instance should be available already in preload function.