mirror of
https://github.com/Stirling-Tools/Stirling-PDF.git
synced 2025-08-26 06:09:23 +00:00
Update frontend/src/utils/toolErrorHandler.ts
Co-authored-by: James Brunton <jbrunton96@gmail.com>
This commit is contained in:
parent
2ef9de8aa3
commit
af6ef53aed
@ -36,8 +36,7 @@ const extractFromJsonData = (data: unknown): string | null => {
|
||||
/**
|
||||
* Default error extractor that follows the standard pattern
|
||||
*/
|
||||
export const extractErrorMessage = (error: unknown): string => {
|
||||
const typedError = error as ToolError;
|
||||
export const extractErrorMessage = (error: ToolError): string => {
|
||||
|
||||
// Try response.data first
|
||||
if (typedError.response?.data) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user