mm_expand 1.7.3 → 1.7.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +2 -2
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -511,13 +511,13 @@ Eventer.prototype.on = function(key, func) {
511
511
  * @param {String} key 事件关键
512
512
  * @param {Object} params 传递参数
513
513
  */
514
- Eventer.prototype.run = function(key, params) {
514
+ Eventer.prototype.run = function(key, ...params) {
515
515
  var events = this.dict;
516
516
  var list = events[key];
517
517
  if (list) {
518
518
  for (var i = 0; i < list.length; i++) {
519
519
  try {
520
- list[i](params);
520
+ list[i](...params);
521
521
  } catch (e) {
522
522
  console.error(e);
523
523
  //TODO handle the exception
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mm_expand",
3
- "version": "1.7.3",
3
+ "version": "1.7.4",
4
4
  "description": "这是超级美眉原型函数拓展模块,更有利于对string、array、object的操作,避免出错,简化业务逻辑。",
5
5
  "main": "index.js",
6
6
  "scripts": {