feat: updated user model
This commit is contained in:
parent
750a7f21d1
commit
60f39158f5
@ -1,8 +1,11 @@
|
|||||||
import { ObjectId } from 'mongodb'
|
import { ObjectId } from 'mongodb'
|
||||||
|
import { UserRole } from '../types'
|
||||||
|
|
||||||
export class User {
|
export class User {
|
||||||
constructor(
|
constructor(
|
||||||
public name: string,
|
public name: string,
|
||||||
|
public npub: string[],
|
||||||
|
public role: UserRole,
|
||||||
public id?: ObjectId
|
public id?: ObjectId
|
||||||
) {}
|
) {}
|
||||||
}
|
}
|
||||||
|
5
src/types/user.ts
Normal file
5
src/types/user.ts
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
export enum UserRole {
|
||||||
|
User = 'user',
|
||||||
|
Reviewer = 'reviewer',
|
||||||
|
Producer = 'producer'
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user