add better error logging for fragment translation debugging

This commit is contained in:
Russell Ballestrini 2025-07-11 22:04:44 -04:00
parent b7563d0f2b
commit 60743c5bfb

View file

@ -458,7 +458,8 @@ ${preservedText}`;
return translatedText;
} catch (error) {
console.error("Fragment translation error:", error);
throw new Error("Fragment translation failed. Please try again.");
console.error("Error stack:", error.stack);
throw new Error(`Fragment translation failed: ${error.message}`);
}
}