Skip to content

Commit b067cfa

Browse files
Merge pull request cerebral#78 from cerebral/moduleFactory
fix(overmind): fix dynamic module identification
2 parents b1a61c9 + d04a416 commit b067cfa

File tree

1 file changed

+3
-1
lines changed
  • packages/node_modules/overmind/src

1 file changed

+3
-1
lines changed

packages/node_modules/overmind/src/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,9 @@ export default class App<
482482
private mutateModuleFunctionsIntoModules(config: Configuration) {
483483
if (config.modules) {
484484
Object.keys(config.modules).forEach((key) => {
485-
config.modules[key] = (config.modules[key] as any)(key)
485+
if (typeof config.modules[key] === 'function') {
486+
config.modules[key] = (config.modules[key] as any)(key)
487+
}
486488
})
487489
}
488490
}

0 commit comments

Comments
 (0)