mirror of
https://github.com/diced/zipline.git
synced 2025-04-11 23:31:17 -05:00
customizable user id length
This commit is contained in:
parent
31082b4600
commit
7c6f30544a
1 changed files with 2 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
|||
import { Column, Entity, PrimaryColumn, PrimaryGeneratedColumn } from "typeorm";
|
||||
import { randomId } from "../util";
|
||||
import config from '../../config.json';
|
||||
|
||||
@Entity()
|
||||
export class User {
|
||||
|
@ -22,7 +23,7 @@ export class User {
|
|||
this.username = options.username;
|
||||
this.password = options.password;
|
||||
this.administrator = options.administrator;
|
||||
this.token = randomId(32)
|
||||
this.token = randomId(config.user.randomIDSize)
|
||||
return this;
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue