Skip to content

Commit 0006ec5

Browse files
committed
Fixed explicit mutations issue #45
1 parent 834dfbe commit 0006ec5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/module.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ function extractModulesFromPrototype( cls :VuexModuleConstructor ) {
140140
const getters :Record<DictionaryField, any> = {};
141141
const descriptors :PropertyDescriptorMap = getDescriptors( cls.prototype );
142142
const gettersList :string[] = Object.keys( descriptors ).filter( field => descriptors[ field ].get );
143-
const explicitMutationNames :string[] = cls.prototype.__explicit_mutations_names__;
143+
const explicitMutationNames :string[] = cls.prototype.__explicit_mutations_names__ || [];
144144
const actionNames = cls.prototype.__actions__ || [];
145145

146146
for( let field in descriptors ) {

0 commit comments

Comments
 (0)