File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -58,9 +58,7 @@ function getNetworkMultiplierFromString(condition: string | null): number {
5858 return 1 ;
5959}
6060
61- function getExtensionFromMimeType (
62- mimeType : 'image/png' | 'image/jpeg' | 'image/webp' ,
63- ) {
61+ function getExtensionFromMimeType ( mimeType : string ) {
6462 switch ( mimeType ) {
6563 case 'image/png' :
6664 return 'png' ;
@@ -369,7 +367,7 @@ export class McpContext implements Context {
369367 return { filename} ;
370368 } catch ( err ) {
371369 this . logger ( err ) ;
372- throw new Error ( 'Could not save a screenshot to a file' ) ;
370+ throw new Error ( 'Could not save a screenshot to a file' , { cause : err } ) ;
373371 }
374372 }
375373 async saveFile (
@@ -382,7 +380,7 @@ export class McpContext implements Context {
382380 return { filename} ;
383381 } catch ( err ) {
384382 this . logger ( err ) ;
385- throw new Error ( 'Could not save a screenshot to a file' ) ;
383+ throw new Error ( 'Could not save a screenshot to a file' , { cause : err } ) ;
386384 }
387385 }
388386
You can’t perform that action at this time.
0 commit comments