diff --git a/src/api/acts/roomContent.ts b/src/api/acts/roomContent.ts index f9e14b9..474bd28 100644 --- a/src/api/acts/roomContent.ts +++ b/src/api/acts/roomContent.ts @@ -41,7 +41,7 @@ export const getCategories: Act = { } }; -export const addCategories: Act = { +export const addCategory: Act = { state: STATE.client | STATE.remote, right: 0, data: { @@ -54,7 +54,7 @@ export const addCategories: Act = { func: async (client: Client, data: any, aws: (code: string, data: any) => void) => { if (!checkSelfTag(data.server)) { if (client.state != STATE.client) return void aws("error", "right"); - let resp = await client.pass(data.server, "getCategories", data); + let resp = await client.pass(data.server, "addCategory", data); aws(resp.state, resp.data); return; } @@ -229,3 +229,4 @@ export const getProducts: Act = { aws("ok", out.filter(d => d != null)); } }; +