mirror of
https://github.com/voideditor/void
synced 2026-05-24 09:58:23 +00:00
ignore e.stack
This commit is contained in:
parent
8ff4f1c6e1
commit
9f27b17f11
2 changed files with 3 additions and 3 deletions
|
|
@ -15,7 +15,7 @@ import { getCmdKey } from '../../../getCmdKey.js';
|
|||
type Details = {
|
||||
message: string,
|
||||
name: string,
|
||||
// stack: string | null,
|
||||
stack: string | null,
|
||||
cause: string | null,
|
||||
code: string | null,
|
||||
additional: Record<string, any>
|
||||
|
|
@ -48,7 +48,7 @@ const getErrorDetails = (error: unknown) => {
|
|||
details = {
|
||||
name: e.name || 'Error',
|
||||
message: message,
|
||||
// stack: e.stack || null, // can we remove this? it looks awful and not sure stack is ever useful
|
||||
stack: null, // e.stack is ignored because it's ugly and not very useful
|
||||
cause: e.cause ? String(e.cause) : null,
|
||||
code: e.code || null,
|
||||
additional: {}
|
||||
|
|
|
|||
|
|
@ -147,7 +147,7 @@ registerAction2(class extends Action2 {
|
|||
}
|
||||
async run(accessor: ServicesAccessor): Promise<void> {
|
||||
const stateService = accessor.get(IVoidSidebarStateService)
|
||||
stateService.setState({ isHistoryOpen: false, currentTab: 'settings' })
|
||||
stateService.setState({ isHistoryOpen: false, currentTab: stateService.state.currentTab === 'settings' ? 'chat' : 'settings' })
|
||||
stateService.fireBlurChat()
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Reference in a new issue