feat(wip): 群组
This commit is contained in:
13
server/data/ChatGroup.ts
Normal file
13
server/data/ChatGroup.ts
Normal file
@@ -0,0 +1,13 @@
|
||||
import chalk from "chalk"
|
||||
import Chat from "./Chat.ts"
|
||||
import User from "./User.ts"
|
||||
|
||||
export default class ChatGroup extends Chat {
|
||||
static fromChat(chat: Chat) {
|
||||
return new ChatGroup(chat.bean)
|
||||
}
|
||||
|
||||
static createGroup(chatId?: string) {
|
||||
return this.create(chatId || crypto.randomUUID(), 'group')
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user