@tomei/sso 0.29.1 → 0.29.3

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tomei/sso",
3
- "version": "0.29.1",
3
+ "version": "0.29.3",
4
4
  "description": "Tomei SSO Package",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -309,9 +309,9 @@ export class LoginUser extends LoginUserBase {
309
309
  const userAttr: IUserAttr = {
310
310
  UserId: user.UserId,
311
311
  UserName: user.UserName,
312
- FullName: user.Staff.FullName,
313
- IDNo: user.Staff.IdNo,
314
- ContactNo: user.Staff.Mobile,
312
+ FullName: user?.Staff?.FullName,
313
+ IDNo: user?.Staff?.IdNo,
314
+ ContactNo: user?.Staff?.Mobile,
315
315
  Email: user.Email,
316
316
  Password: user.Password,
317
317
  Status: user.Status,
@@ -329,7 +329,7 @@ export class LoginUser extends LoginUserBase {
329
329
  CreatedAt: user.CreatedAt,
330
330
  UpdatedById: user.UpdatedById,
331
331
  UpdatedAt: user.UpdatedAt,
332
- staffs: user.Staff,
332
+ staffs: user?.Staff,
333
333
  };
334
334
 
335
335
  return new LoginUser(sessionService, dbTransaction, userAttr);
@@ -22,6 +22,7 @@ export default class UserGroupModel extends Model {
22
22
  primaryKey: true,
23
23
  type: DataType.INTEGER,
24
24
  allowNull: false,
25
+ autoIncrement: true,
25
26
  })
26
27
  UserGroupId: number;
27
28