cgserver 13.2.19 → 13.2.21

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.
@@ -15,7 +15,6 @@ exports.Errcode = Errcode;
15
15
  * 1-100
16
16
  */
17
17
  class FrameworkErrorCode {
18
- Wrong_Params = new Errcode(1, "参数错误");
19
18
  Verify_failed = new Errcode(2, "验证失败");
20
19
  Account_Create_Failed = new Errcode(3, "账号创建失败");
21
20
  User_Create_Failed = new Errcode(4, "角色创建失败");
@@ -38,6 +37,7 @@ class FrameworkErrorCode {
38
37
  Wrong_Phone_Code = new Errcode(20, "验证码不正确");
39
38
  No_Mongo = new Errcode(21, "未开通Mongo数据库");
40
39
  Mongo_Error = new Errcode(22, "Mongo数据库异常");
40
+ Wrong_Params = new Errcode(23, "参数错误");
41
41
  constructor() { }
42
42
  }
43
43
  exports.FrameworkErrorCode = FrameworkErrorCode;
@@ -444,7 +444,7 @@ class core {
444
444
  totalProbability = eval(probabilitys.join("+"));
445
445
  }
446
446
  if (totalProbability > 1) {
447
- random = _.random(totalProbability);
447
+ random = _.random(totalProbability - 1);
448
448
  }
449
449
  else {
450
450
  random = Math.random();
@@ -8,7 +8,6 @@ export declare class Errcode {
8
8
  * 1-100
9
9
  */
10
10
  export declare class FrameworkErrorCode {
11
- Wrong_Params: Errcode;
12
11
  Verify_failed: Errcode;
13
12
  Account_Create_Failed: Errcode;
14
13
  User_Create_Failed: Errcode;
@@ -31,5 +30,6 @@ export declare class FrameworkErrorCode {
31
30
  Wrong_Phone_Code: Errcode;
32
31
  No_Mongo: Errcode;
33
32
  Mongo_Error: Errcode;
33
+ Wrong_Params: Errcode;
34
34
  constructor();
35
35
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cgserver",
3
- "version": "13.2.19",
3
+ "version": "13.2.21",
4
4
  "author": "trojan",
5
5
  "type": "commonjs",
6
6
  "description": "free for all.Websocket or Http",