|
@@ -1,5 +1,5 @@
|
|
|
/*!
|
|
|
- * vuex v3.5.0
|
|
|
+ * vuex v3.5.1
|
|
|
* (c) 2020 Evan You
|
|
|
* @license MIT
|
|
|
*/
|
|
@@ -265,7 +265,21 @@ ModuleCollection.prototype.register = function register (path, rawModule, runtim
|
|
|
ModuleCollection.prototype.unregister = function unregister (path) {
|
|
|
var parent = this.get(path.slice(0, -1));
|
|
|
var key = path[path.length - 1];
|
|
|
- if (!parent.getChild(key).runtime) { return }
|
|
|
+ var child = parent.getChild(key);
|
|
|
+
|
|
|
+ if (!child) {
|
|
|
+ if ((process.env.NODE_ENV !== 'production')) {
|
|
|
+ console.warn(
|
|
|
+ "[vuex] trying to unregister module '" + key + "', which is " +
|
|
|
+ "not registered"
|
|
|
+ );
|
|
|
+ }
|
|
|
+ return
|
|
|
+ }
|
|
|
+
|
|
|
+ if (!child.runtime) {
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
parent.removeChild(key);
|
|
|
};
|
|
@@ -1214,7 +1228,7 @@ function pad (num, maxLength) {
|
|
|
var index_cjs = {
|
|
|
Store: Store,
|
|
|
install: install,
|
|
|
- version: '3.5.0',
|
|
|
+ version: '3.5.1',
|
|
|
mapState: mapState,
|
|
|
mapMutations: mapMutations,
|
|
|
mapGetters: mapGetters,
|