bug fix
This commit is contained in:
parent
bd83abba30
commit
9efffabe80
2 changed files with 2 additions and 4 deletions
|
@ -96,7 +96,6 @@ export const createRoom: Act = {
|
|||
right: PERMISSIONS.CAN_USE_API,
|
||||
data: {
|
||||
room: "name-100",
|
||||
server: "string", // Unused/Ignored at the Moment
|
||||
title: "string-255",
|
||||
description: "string-255",
|
||||
visibility: "number",
|
||||
|
@ -141,7 +140,6 @@ export const deleteRoom: Act = {
|
|||
right: PERMISSIONS.CAN_USE_API,
|
||||
data: {
|
||||
room: "string",
|
||||
server: "string", // Unused/Ignored at the Moment
|
||||
},
|
||||
func: async (client: Client, data: any, aws: (code: string, data: any) => void) => {
|
||||
let req = await remove(rooms)
|
||||
|
|
|
@ -68,7 +68,7 @@ export class Client {
|
|||
.where(and(
|
||||
eq(rooms.name, name),
|
||||
eq(roomMembers.name, this.name),
|
||||
eq(roomMembers.server, this.server.tag)
|
||||
eq(roomMembers.server, this.state == STATE.client ? "local" : this.server.tag)
|
||||
))
|
||||
.query(db);
|
||||
if (query.length == 0) return -1;
|
||||
|
@ -81,7 +81,7 @@ export class Client {
|
|||
eq(rooms.name, name),
|
||||
eq(roomMembers.admin, true),
|
||||
eq(roomMembers.name, this.name),
|
||||
eq(roomMembers.server, this.server.tag)
|
||||
eq(roomMembers.server, this.state == STATE.client ? "local" : this.server.tag)
|
||||
))
|
||||
.query(db);
|
||||
if (query.length == 0) return -1;
|
||||
|
|
Loading…
Reference in a new issue