mirror of
https://github.com/owncast/owncast.git
synced 2025-11-03 21:08:36 +08:00
Use auth'ed admin chat messages endpoint to get history
This commit is contained in:
@ -48,7 +48,7 @@ export default function Chat() {
|
|||||||
|
|
||||||
const getInfo = async () => {
|
const getInfo = async () => {
|
||||||
try {
|
try {
|
||||||
const result = await fetchData(CHAT_HISTORY, { auth: false });
|
const result = await fetchData(CHAT_HISTORY, { auth: true });
|
||||||
setMessages(result);
|
setMessages(result);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log("==== error", error);
|
console.log("==== error", error);
|
||||||
|
|||||||
@ -35,7 +35,7 @@ export const LOGS_ALL = `${API_LOCATION}logs`;
|
|||||||
export const LOGS_WARN = `${API_LOCATION}logs/warnings`;
|
export const LOGS_WARN = `${API_LOCATION}logs/warnings`;
|
||||||
|
|
||||||
// Get chat history
|
// Get chat history
|
||||||
export const CHAT_HISTORY = `${NEXT_PUBLIC_API_HOST}api/chat`;
|
export const CHAT_HISTORY = `${API_LOCATION}chat/messages`;
|
||||||
|
|
||||||
// Get chat history
|
// Get chat history
|
||||||
export const UPDATE_CHAT_MESSGAE_VIZ = `${NEXT_PUBLIC_API_HOST}api/admin/chat/updatemessagevisibility`;
|
export const UPDATE_CHAT_MESSGAE_VIZ = `${NEXT_PUBLIC_API_HOST}api/admin/chat/updatemessagevisibility`;
|
||||||
|
|||||||
Reference in New Issue
Block a user