tests & image-request on google & inspirobot & front
This commit is contained in:
@@ -2,7 +2,19 @@ import axios from "axios";
|
||||
|
||||
|
||||
|
||||
export const getRoom = async () => {
|
||||
|
||||
export const getRoom = async (_id) => {
|
||||
try {
|
||||
const response = await axios.get("/room", {_id});
|
||||
console.log(response.data)
|
||||
return response.data;
|
||||
} catch (error) {
|
||||
console.log("ERROR", error.response.data)
|
||||
return error.response.data;
|
||||
}
|
||||
};
|
||||
|
||||
export const getRooms = async () => {
|
||||
try {
|
||||
const response = await axios.get("/room", {});
|
||||
console.log(response.data)
|
||||
|
Reference in New Issue
Block a user