fix: add error logging for various API calls across components
Deploy to VPS / deploy (push) Successful in 2m20s
Deploy to VPS / deploy (push) Successful in 2m20s
This commit is contained in:
@@ -29,8 +29,8 @@ export default function AnalysisPage() {
|
||||
const { messagesApi } = await import("@/lib/api");
|
||||
try {
|
||||
await messagesApi.reanalyze(id);
|
||||
} catch {
|
||||
/* ignore */
|
||||
} catch (err) {
|
||||
console.error("analysis/reanalyze:", err);
|
||||
}
|
||||
}, []);
|
||||
|
||||
|
||||
@@ -82,8 +82,8 @@ export default function DashboardPage() {
|
||||
const detail = await dashboardApi.getUserDetail(userId);
|
||||
setActiveUser(detail);
|
||||
setView("user-detail");
|
||||
} catch {
|
||||
/* ignore */
|
||||
} catch (err) {
|
||||
console.error("dashboard/userDetail:", err);
|
||||
}
|
||||
}}
|
||||
/>
|
||||
@@ -97,8 +97,8 @@ export default function DashboardPage() {
|
||||
const detail = await dashboardApi.getChannelDetail(chId);
|
||||
setActiveChannel(detail);
|
||||
setView("channel-detail");
|
||||
} catch {
|
||||
/* ignore */
|
||||
} catch (err) {
|
||||
console.error("dashboard/channelDetail:", err);
|
||||
}
|
||||
}}
|
||||
/>
|
||||
|
||||
@@ -121,8 +121,8 @@ export default function MessagesPage() {
|
||||
const { messagesApi } = await import("@/lib/api");
|
||||
try {
|
||||
await messagesApi.reanalyze(id);
|
||||
} catch {
|
||||
/* ignore */
|
||||
} catch (err) {
|
||||
console.error("messages/reanalyze:", err);
|
||||
}
|
||||
}, []);
|
||||
|
||||
@@ -131,8 +131,8 @@ export default function MessagesPage() {
|
||||
const { messagesApi } = await import("@/lib/api");
|
||||
try {
|
||||
await messagesApi.reanalyzeBatch(guildId);
|
||||
} catch {
|
||||
/* ignore */
|
||||
} catch (err) {
|
||||
console.error("messages/reanalyzeBatch:", err);
|
||||
}
|
||||
}, [guildId]);
|
||||
|
||||
|
||||
@@ -238,7 +238,8 @@ export default function VoicePage() {
|
||||
await voiceApi.sendCommand(
|
||||
checked ? "voice:transmit:start" : "voice:transmit:stop",
|
||||
);
|
||||
} catch {
|
||||
} catch (err) {
|
||||
console.error("voice/mic:", err);
|
||||
setMicActive(!checked);
|
||||
}
|
||||
}}
|
||||
|
||||
Reference in New Issue
Block a user