mirror of
https://github.com/hanzoai/code.git
synced 2026-09-30 20:53:35 +00:00
improve message
This commit is contained in:
@@ -34,7 +34,8 @@ const getErrorDetails = (error: unknown) => {
|
||||
}
|
||||
// sometimes error is an object but not an Error
|
||||
else if (typeof error === 'object') {
|
||||
e = new Error('More details below.', { cause: JSON.stringify(error) })
|
||||
e = new Error(`The server didn't give a very useful error message. More details below.`, { cause: JSON.stringify(error) })
|
||||
|
||||
}
|
||||
else {
|
||||
e = new Error(String(error))
|
||||
|
||||
Reference in New Issue
Block a user